src/Titon/Model/Model.php
public static function update($id, array $data, array $options = []) {
        $model = static::find($id);

        if ($model->exists()) {
            $model->fill($data);

            if ($model->save($options)) {
                return $model;
            }
        }

        return null;
    }
public static function update($id, array $data, array $options = []) {
        $model = static::find($id);

        if ($model->exists()) {
            $model->fill($data);

            if ($model->save($options)) {
                return $model;
            }
        }

        return null;
    }
public static function update ( $ id , array $ data , array $ options = [ ] ) { $ model = static :: find ( $ id ) ; if ( $ model -> exists ( ) ) { $ model -> fill ( $ data ) ; if ( $ model -> save ( $ options ) ) { return $ model ; } } return null ; }
Update a model by ID by finding the record in the database, filling the data, and attempting to save.
Return the model instance on success, or a null on failure.

@see \Titon\Db\Repository::update()

@param int $id
@param array $data
@param array $options
@return \Titon\Model\Model
Update a model by ID by finding the record in the database filling the data and attempting to save . Return the model instance on success or a null on failure .