Fix links from player pages to the ttyrec archive.

RogueGame.getPlayer() was setting the "name" field to self.uname
instead of the player's name.

Bugs like this are why I need to set up an actual testing server.
This commit is contained in:
John "Elwin" Edwards 2015-08-06 17:07:40 -04:00
parent d74cb0c0bd
commit aa1d817df4

View file

@ -437,7 +437,7 @@ class RogueGame(Game):
cur.execute(qstr, [player]) cur.execute(qstr, [player])
for record in cur: for record in cur:
ndict = {"game": self} ndict = {"game": self}
ndict["name"] = self.uname ndict["name"] = player
ndict["endt"] = record[0] ndict["endt"] = record[0]
ndict["score"] = record[1] ndict["score"] = record[1]
ndict["xl"] = record[2] ndict["xl"] = record[2]
@ -519,7 +519,7 @@ class ARogueGame(Game):
cur.execute(qstr, [player]) cur.execute(qstr, [player])
for record in cur: for record in cur:
ndict = {"game": self} ndict = {"game": self}
ndict["name"] = self.uname ndict["name"] = player
ndict["endt"] = record[0] ndict["endt"] = record[0]
ndict["score"] = record[1] ndict["score"] = record[1]
ndict["xl"] = record[2] ndict["xl"] = record[2]