modify() public method
Performs 'findAndModify' query and returns a single row of result.
public array|null modify ( $update, $options = [], $db = null ) | ||
---|---|---|
$update | array |
Update criteria |
$options | array |
List of options in format: optionName => optionValue. |
$db | yii\mongodb\Connection |
The Mongo connection used to execute the query. |
return | array|null |
The original document, or the modified document when $options['new'] is set. |
Please login to continue.