avoid triggering a warning when using the Notifications API in an insecure context

pull/1/head
ansuz 5 years ago
parent c7cea7fae3
commit c9be2fae36

@ -6,7 +6,7 @@ define(['/api/config'], function (ApiConfig) {
var isSupported = Module.isSupported = function () { var isSupported = Module.isSupported = function () {
return typeof(window.Notification) === 'function'; return typeof(window.Notification) === 'function' && window.location.protocol === 'https:';
}; };
var hasPermission = Module.hasPermission = function () { var hasPermission = Module.hasPermission = function () {

Loading…
Cancel
Save