aboutsummaryrefslogtreecommitdiffstats
path: root/app/scripts/lib/is-popup-or-notification.js
diff options
context:
space:
mode:
Diffstat (limited to 'app/scripts/lib/is-popup-or-notification.js')
-rw-r--r--app/scripts/lib/is-popup-or-notification.js8
1 files changed, 8 insertions, 0 deletions
diff --git a/app/scripts/lib/is-popup-or-notification.js b/app/scripts/lib/is-popup-or-notification.js
new file mode 100644
index 000000000..5c38ac823
--- /dev/null
+++ b/app/scripts/lib/is-popup-or-notification.js
@@ -0,0 +1,8 @@
+module.exports = function isPopupOrNotification() {
+ const url = window.location.href
+ if (url.match(/popup.html$/)) {
+ return 'popup'
+ } else {
+ return 'notification'
+ }
+}