Skip to content

Commit

Permalink
fix #13
Browse files Browse the repository at this point in the history
  • Loading branch information
JiLiZART committed Oct 19, 2014
1 parent 80fead1 commit 2d12406
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions models/Answer.php
Original file line number Diff line number Diff line change
Expand Up @@ -149,9 +149,9 @@ public static function applyOrder(ActiveQuery $query, $order)
/**
* This is invoked after the record is saved.
*/
public function afterSave($insert)
public function afterSave($insert, $changedAttribute)
{
parent::afterSave($insert);
parent::afterSave($insert, $changedAttribute);

if ($insert) {
Question::incrementAnswers($this->question_id);
Expand All @@ -166,4 +166,4 @@ public function afterDelete()
parent::afterDelete();
Question::decrementAnswers($this->question_id);
}
}
}

0 comments on commit 2d12406

Please sign in to comment.