From cd678d86e87669631848939b1fe9bd91e10b26c8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Florian=20M=C3=BCllner?= Date: Tue, 13 Jun 2017 06:49:07 +0200 Subject: [PATCH] notificationDaemon: Avoid access to undefined property Avoid a warning when assigning from an undefined property by making sure to pass a proper null value instead. https://bugzilla.gnome.org/show_bug.cgi?id=781471 --- js/ui/notificationDaemon.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/js/ui/notificationDaemon.js b/js/ui/notificationDaemon.js index 315bfdb17..c8cba607b 100644 --- a/js/ui/notificationDaemon.js +++ b/js/ui/notificationDaemon.js @@ -186,7 +186,8 @@ const FdoNotificationDaemon = new Lang.Class({ return source; } - source = new FdoNotificationDaemonSource(title, pid, sender, ndata ? ndata.hints['desktop-entry'] : null); + let appId = ndata ? ndata.hints['desktop-entry'] || null : null; + source = new FdoNotificationDaemonSource(title, pid, sender, appId); this._sources.push(source); source.connect('destroy', Lang.bind(this, function() {