Added return values for models::save
This commit is contained in:
parent
05a3cf927b
commit
c64d97fae6
5 changed files with 10 additions and 1 deletions
|
@ -39,6 +39,8 @@ class CommentModel extends AbstractCrudModel
|
|||
|
||||
Database::exec($stmt);
|
||||
});
|
||||
|
||||
return $comment;
|
||||
}
|
||||
|
||||
public static function remove($comment)
|
||||
|
|
|
@ -113,6 +113,8 @@ class PostModel extends AbstractCrudModel
|
|||
Database::exec($stmt);
|
||||
}
|
||||
});
|
||||
|
||||
return $post;
|
||||
}
|
||||
|
||||
public static function remove($post)
|
||||
|
|
|
@ -32,7 +32,8 @@ class TagModel extends AbstractCrudModel
|
|||
|
||||
Database::exec($stmt);
|
||||
});
|
||||
return $tag->id;
|
||||
|
||||
return $tag;
|
||||
}
|
||||
|
||||
public static function remove($tag)
|
||||
|
|
|
@ -33,6 +33,8 @@ class TokenModel extends AbstractCrudModel
|
|||
|
||||
Database::exec($stmt);
|
||||
});
|
||||
|
||||
return $token;
|
||||
}
|
||||
|
||||
public static function findByToken($key, $throw = true)
|
||||
|
|
|
@ -63,6 +63,8 @@ class UserModel extends AbstractCrudModel
|
|||
|
||||
Database::exec($stmt);
|
||||
});
|
||||
|
||||
return $user;
|
||||
}
|
||||
|
||||
public static function remove($user)
|
||||
|
|
Loading…
Reference in a new issue