Image and comment counts not shown for user #0
git-svn-id: file:///home/shish/svn/shimmie2/trunk@416 7f39781d-f577-437e-ae19-be835c7a54ca
This commit is contained in:
parent
87722ff98a
commit
1c8619d9e9
@ -51,12 +51,12 @@ class User {
|
|||||||
|
|
||||||
public function get_image_count() {
|
public function get_image_count() {
|
||||||
global $database;
|
global $database;
|
||||||
return $database->db->GetOne("SELECT COUNT(*) AS count FROM images WHERE owner_id=?", $this->id);
|
return $database->db->GetOne("SELECT COUNT(*) AS count FROM images WHERE owner_id=?", array($this->id));
|
||||||
}
|
}
|
||||||
|
|
||||||
public function get_comment_count() {
|
public function get_comment_count() {
|
||||||
global $database;
|
global $database;
|
||||||
return $database->db->GetOne("SELECT COUNT(*) AS count FROM comments WHERE owner_id=?", $this->id);
|
return $database->db->GetOne("SELECT COUNT(*) AS count FROM comments WHERE owner_id=?", array($this->id));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
?>
|
?>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user