code: def update(self, instance, condition):
          
          item = self.dbi.get(condition)
          if item is None:
              return None
          item.update(instance.as_dict())
          self.dbi.update(item, condition)
          return item.eid
docs: Update the instance to the database
  
          :param instance: an instance of modeled data object
          :param condition: condition evaluated to determine record(s) to update
          :returns: record id updated or None
          :rtype: int