Merge pull request #3312 from rabuzarus/20170409_-_fix_desktop_notifs

Bugfix: Desktop-notifs - show notifs which have seen = false or seen = 0
This commit is contained in:
Hypolite Petovan 2017-04-09 09:22:20 -04:00 committed by GitHub
커밋 b9c0c114fb
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제

파일 보기

@ -249,7 +249,7 @@
// Desktop Notifications
$(data.notifications.reverse()).each(function(key, e){
notification_id = parseInt(e.timestamp);
if (notification_lastitem !== null && notification_id > notification_lastitem && !e.seen) {
if (notification_lastitem !== null && notification_id > notification_lastitem && Number(e.seen) === 0) {
if (getNotificationPermission() === "granted") {
var notification = new Notification(document.title, {
body: decodeHtml(e.message.replace('→ ', '').format(e.name)),