ERepublik: Set default values for party__*.
parent
437e553995
commit
4baad7f139
|
@ -64,7 +64,11 @@ def getCitizen(irc, name):
|
|||
def flatten_subdicts(dicts):
|
||||
"""Change dict of dicts into a dict of strings/integers. Useful for
|
||||
using in string formatting."""
|
||||
flat = {}
|
||||
flat = {
|
||||
'party__name': 'none',
|
||||
'party__id': 0,
|
||||
'party__role': 'N/A',
|
||||
}
|
||||
for key, value in dicts.items():
|
||||
if isinstance(value, dict):
|
||||
for subkey, subvalue in value.items():
|
||||
|
|
Loading…
Reference in New Issue