code: async def update(query):
      
      assert isinstance(query, peewee.Update),\
          ("Error, trying to run update coroutine"
           "with wrong query class %s" % str(query))
  
      cursor = await _execute_query_async(query)
      rowcount = cursor.rowcount
  
      await cursor.release()
      return rowcount
docs: Perform UPDATE query asynchronously. Returns number of rows updated.