code: def update_db(self, userkarma, username):
          
  
          kt = self.db.session.query(KarmaTable)
          for user in userkarma:
              if user != username:
                  # Modify the db accourdingly
                  urow = kt.filter(KarmaTable.user == ude(user)).first()
                  # If the user doesn't exist, create it
                  if not urow:
                      urow = KarmaTable(ude(user))
                  urow.kcount += userkarma[user]
                  self.db.session.add(urow)
          self.db.session.commit()
docs: Change the users karma by the karma amount (either 1 or -1)