From 26f7d7a21a5a3612cee088f7641a2e2f8e67f5c1 Mon Sep 17 00:00:00 2001 From: Menno van Starrenburg Date: Tue, 1 Nov 2016 15:10:56 +0100 Subject: [PATCH] removed the n.close wrapper fixed some grammer and spelling issues --- src/push-notifications.service.ts | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/push-notifications.service.ts b/src/push-notifications.service.ts index 2543568..1adc866 100644 --- a/src/push-notifications.service.ts +++ b/src/push-notifications.service.ts @@ -27,12 +27,12 @@ export class PushNotificationsService { return new Observable(obs => { if (!('Notification' in window)) { - obs.error('Notifications are not available in this envirement'); + obs.error('Notifications are not available in this environment'); obs.complete(); } if (this.permission !== 'granted') { - obs.error(`The user didn't granted you permission to send push notifications`); + obs.error(`The user hasn't granted you permission to send push notifications`); obs.complete(); } @@ -42,10 +42,6 @@ export class PushNotificationsService { n.onclick = (e) => obs.next({notification: n, event: e}); n.onerror = (e) => obs.error({notification: n, event: e}); n.onclose = () => obs.complete(); - n.close = () => { - n.close.bind(n); - obs.complete(); - }; }); }