summaryrefslogtreecommitdiff
path: root/app/Model
diff options
context:
space:
mode:
authorMax Kamashev <kamashev@gollard.ru>2015-09-30 09:19:19 +0300
committerMax Kamashev <kamashev@gollard.ru>2015-09-30 09:19:19 +0300
commit930406bf70e42413a83114b9530b3f63ccf9419f (patch)
tree553b2ba09cfe6d176c3e32529dcece5a9807cf4e /app/Model
parentcb8211ab8b1d1dc44ccfcd86a6bf2c71ad862264 (diff)
refs #1245 - Renamed argument
Diffstat (limited to 'app/Model')
-rw-r--r--app/Model/Subtask.php8
-rw-r--r--app/Model/SubtaskTimeTracking.php2
2 files changed, 5 insertions, 5 deletions
diff --git a/app/Model/Subtask.php b/app/Model/Subtask.php
index c222fe2b..3c6269f1 100644
--- a/app/Model/Subtask.php
+++ b/app/Model/Subtask.php
@@ -233,17 +233,17 @@ class Subtask extends Base
* Update
*
* @access public
- * @param array $values Form values
- * @param array $options Additional options. If passed [quietly => true] - will not be called an event
+ * @param array $values Form values
+ * @param bool $fire_events If true, will be called an event
* @return bool
*/
- public function update(array $values, array $options = null)
+ public function update(array $values, $fire_events = true)
{
$this->prepare($values);
$subtask = $this->getById($values['id']);
$result = $this->db->table(self::TABLE)->eq('id', $values['id'])->save($values);
- if ($result && empty($options['quietly'])) {
+ if ($result && $fire_events) {
$event = $subtask;
$event['changes'] = array_diff_assoc($values, $subtask);
$this->container['dispatcher']->dispatch(self::EVENT_UPDATE, new SubtaskEvent($event));
diff --git a/app/Model/SubtaskTimeTracking.php b/app/Model/SubtaskTimeTracking.php
index 7381060e..4a18c8aa 100644
--- a/app/Model/SubtaskTimeTracking.php
+++ b/app/Model/SubtaskTimeTracking.php
@@ -345,7 +345,7 @@ class SubtaskTimeTracking extends Base
'id' => $subtask['id'],
'time_spent' => $subtask['time_spent'] + $time_spent,
'task_id' => $subtask['task_id'],
- ), array('quietly' => true));
+ ), false);
}
/**