notificationDaemon: Consider hyphens for app ID to object path translations

Some application IDs contain hyphens, which are not allowed in D-Bus object
paths, so we need to update the translation by converting them to something
that's a valid object path. This is consistent with what GApplication does.

https://bugzilla.gnome.org/show_bug.cgi?id=787902
This commit is contained in:
Krzesimir Nowak 2016-11-18 15:52:46 +01:00 committed by Mario Sanchez Prada
parent de4c0bdca6
commit ce7ff27c0c

View File

@ -670,7 +670,7 @@ const FdoApplicationIface = '<node> \
const FdoApplicationProxy = Gio.DBusProxy.makeProxyWrapper(FdoApplicationIface);
function objectPathFromAppId(appId) {
return '/' + appId.replace(/\./g, '/');
return '/' + appId.replace(/\./g, '/').replace(/-/g, '_');
}
function getPlatformData() {