Dict are immutable, duh.

This commit is contained in:
jesopo 2018-10-22 13:14:08 +01:00
parent c6b8e4487d
commit 77cf1a6afe

View file

@ -148,7 +148,7 @@ class Module(ModuleManager.BaseModule):
"Please provide a valid positive coin amount") "Please provide a valid positive coin amount")
def _get_default_wallets(self, user): def _get_default_wallets(self, user):
return user.get_setting("default-wallets", WALLET_DEFAULTS) return user.get_setting("default-wallets", WALLET_DEFAULTS.copy())
def _set_default_wallet(self, user, type, wallet): def _set_default_wallet(self, user, type, wallet):
default_wallets = self._get_default_wallets(user) default_wallets = self._get_default_wallets(user)
default_wallets[type.lower()] = wallet.lower() default_wallets[type.lower()] = wallet.lower()