public function modify($update, $options = [], $db = null)
    {
        if (!empty($this->emulateExecution)) {
            return null;
        }

        $this->prepare();

        $collection = $this->getCollection($db);
        if (!empty($this->orderBy)) {
            $options['sort'] = $this->orderBy;
        }

        $options['fields'] = $this->select;
        return $collection->findAndModify($this->composeCondition(), $update, $options);
    }