Fix Notifications Class

This commit is contained in:
rog1121 2014-03-01 17:00:51 -07:00
parent 0b2aecbad9
commit 639d4ccb10
2 changed files with 2 additions and 2 deletions

2
public/include/classes/notification.class.php Normal file → Executable file
View File

@ -58,7 +58,7 @@ class Notification extends Mail {
* @param id int Account ID
* @return array Notification data
**/
public function getNofifications($account_id) {
public function getNotifications($account_id) {
$this->debug->append("STA " . __METHOD__, 4);
$stmt = $this->mysqli->prepare("SELECT * FROM $this->table WHERE account_id = ? ORDER BY time DESC");
if ($stmt && $stmt->bind_param('i', $account_id) && $stmt->execute() && $result = $stmt->get_result())

2
public/include/pages/account/notifications.inc.php Normal file → Executable file
View File

@ -19,7 +19,7 @@ if ($user->isAuthenticated()) {
}
// Fetch notifications
$aNotifications = $notification->getNofifications($_SESSION['USERDATA']['id']);
$aNotifications = $notification->getNotifications($_SESSION['USERDATA']['id']);
if (!$aNotifications) $_SESSION['POPUP'][] = array('CONTENT' => 'Could not find any notifications', 'TYPE' => 'errormsg');
// Fetch global settings