code: protected function update($entity, $where = null, $tableName = null, HydratorInterface $hydrator = null)
      {
          if (! $where) {
              $where = 'id = ' . $entity->getId();
          }
          return parent::update($entity, $where, $tableName, $hydrator);
      }
docs: update - Updates an existing thread in the database.
  
  @param ThreadInterface $entity
  @param String $where
  @param String $tableName
  @param HydratorInterface $hydrator