Skip to content

Commit d687cab

Browse files
committed
FIXED - notifications without email notifications
1 parent f6bfc10 commit d687cab

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

include/classes/notification.class.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -105,8 +105,9 @@ public function getNotificationSettings($account_id) {
105105
**/
106106
public function getNotificationAccountIdByType($strType) {
107107
$this->debug->append("STA " . __METHOD__, 4);
108-
$stmt = $this->mysqli->prepare("SELECT account_id FROM $this->tableSettings WHERE type = ? AND active = 1");
109-
if ($stmt && $stmt->bind_param('s', $strType) && $stmt->execute() && $result = $stmt->get_result()) {
108+
$stmt = $this->mysqli->prepare("SELECT account_id FROM $this->tableSettings WHERE type IN (?, ?) AND active = 1 GROUP BY account_id");
109+
$notStrType = substr('push_'.$strType, 0, 15);
110+
if ($stmt && $stmt->bind_param('ss', $strType, $notStrType) && $stmt->execute() && $result = $stmt->get_result()) {
110111
return $result->fetch_all(MYSQLI_ASSOC);
111112
}
112113
return $this->sqlError('E0046');

0 commit comments

Comments
 (0)