X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=include%2Fenotify.php;h=ebc27309dbe61710b76241f84bfd28e6f8ce0b1d;hb=48dde02e754ba1252e1d488450298d6210a549d5;hp=aa29e117a697d8b6c983c42f1dd5616a9c857cad;hpb=6b6e3e264f55705d47f20cf32213d8d0f0d24efc;p=friendica.git diff --git a/include/enotify.php b/include/enotify.php index aa29e117a6..ebc27309db 100644 --- a/include/enotify.php +++ b/include/enotify.php @@ -105,7 +105,7 @@ function notification($params) { // If so don't create a second notification $p = null; - $p = q("SELECT `id` FROM `notify` WHERE (`type` = %d OR `type` = %d OR `type` = %d) AND `link` = '%s' AND `uid` = %d LIMIT 1", + $p = q("SELECT `id` FROM `notify` WHERE `type` IN (%d, %d, %d) AND `link` = '%s' AND `uid` = %d LIMIT 1", intval(NOTIFY_TAGSELF), intval(NOTIFY_COMMENT), intval(NOTIFY_SHARE), @@ -472,7 +472,7 @@ function notification($params) { // After we've stored everything, look again to see if there are any duplicates and if so remove them $p = null; - $p = q("SELECT `id` FROM `notify` WHERE (`type` = %d OR `type` = %d) AND `link` = '%s' AND `uid` = %d ORDER BY `id`", + $p = q("SELECT `id` FROM `notify` WHERE `type` IN (%d, %d) AND `link` = '%s' AND `uid` = %d ORDER BY `id`", intval(NOTIFY_TAGSELF), intval(NOTIFY_COMMENT), dbesc($params['link']),