projects
/
naja.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
2225b90
)
*REAL* Python has no dict comprehensions.
author
Jeremy Thurgood
<firxen@gmail.com>
Sat, 17 May 2014 20:27:18 +0000
(22:27 +0200)
committer
Jeremy Thurgood
<firxen@gmail.com>
Sat, 17 May 2014 20:27:18 +0000
(22:27 +0200)
naja/gameboard.py
patch
|
blob
|
history
diff --git
a/naja/gameboard.py
b/naja/gameboard.py
index 689c3fd15fcf324d9110763331a6a0eeb93023d2..66c651936099520c0d163786881b7422974fac94 100644
(file)
--- a/
naja/gameboard.py
+++ b/
naja/gameboard.py
@@
-188,7
+188,7
@@
class GameBoard(object):
# Find which cards are at their maximum and exclude them from
# the choice list
counts = {}
- choices =
{card['card_name']: card for card in cards}
+ choices =
dict((card['card_name'], card) for card in cards)
for pos, card in board_locations:
if pos == position:
# skip the card we're replacing if appropriate