about summary refs log tree commit diff
path: root/app/javascript/mastodon/reducers/notifications.js
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2020-11-11 05:36:29 +0100
committerGitHub <noreply@github.com>2020-11-11 05:36:29 +0100
commit4790a126bebddd83cbaf1a8436611536dcc417a0 (patch)
treeb359f7e0789226899ac3f766ad30dd4dddd9b644 /app/javascript/mastodon/reducers/notifications.js
parentf1858f08c2422ad63f1e6acb1670fcf35e3f8d7d (diff)
Add button to dismiss desktop notifications permissions banner (#15141)
Diffstat (limited to 'app/javascript/mastodon/reducers/notifications.js')
-rw-r--r--app/javascript/mastodon/reducers/notifications.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/app/javascript/mastodon/reducers/notifications.js b/app/javascript/mastodon/reducers/notifications.js
index 1d4874717..46a9d5376 100644
--- a/app/javascript/mastodon/reducers/notifications.js
+++ b/app/javascript/mastodon/reducers/notifications.js
@@ -12,6 +12,7 @@ import {
   NOTIFICATIONS_MARK_AS_READ,
   NOTIFICATIONS_SET_BROWSER_SUPPORT,
   NOTIFICATIONS_SET_BROWSER_PERMISSION,
+  NOTIFICATIONS_DISMISS_BROWSER_PERMISSION,
 } from '../actions/notifications';
 import {
   ACCOUNT_BLOCK_SUCCESS,
@@ -250,6 +251,8 @@ export default function notifications(state = initialState, action) {
     return state.set('browserSupport', action.value);
   case NOTIFICATIONS_SET_BROWSER_PERMISSION:
     return state.set('browserPermission', action.value);
+  case NOTIFICATIONS_DISMISS_BROWSER_PERMISSION:
+    return state.set('browserPermission', 'denied');
   default:
     return state;
   }