def getAccountInfo(self, context=None):
     if not self.ok_credentials(context.ctx['id'], context.ctx['key']):
         raise Bank.IncorrectCredentials()
     account_info = Bank.AccountInfo()
     account_info.isPremium = bool(self.user[0]['is_premium'])
     account_info.hasLoan = False
     # account_info.loanInfo =
     account_info.funds = {}
     funds = self.user[0]['funds']
     for (k, v) in funds.items():
         new_key = map_currency(k)
         account_info.funds[new_key] = v
     return account_info