Browse files

Fix a return value for better consistency

  • Loading branch information...
1 parent 95d7fb9 commit fc21f31111081a5b4ea156c7193e14eed6b4eaae @mehlah mehlah committed Dec 20, 2011
Showing with 2 additions and 1 deletion.
  1. +2 −1 models/Post.php
View
3 models/Post.php
@@ -141,8 +141,9 @@ public function comment($record, $params = array()) {
$comment = $comment::create($data);
if (empty($record->_id) || !$comment->save()) {
- return null;
+ return false;
}
+
$data = $comment->data();
$comments = !empty($record->comments) ? $record->comments->data() : array();

0 comments on commit fc21f31

Please sign in to comment.