diff options
Diffstat (limited to 'app/assets/javascripts/broadcast_notification.js')
-rw-r--r-- | app/assets/javascripts/broadcast_notification.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/assets/javascripts/broadcast_notification.js b/app/assets/javascripts/broadcast_notification.js index 2cf2e922f68..34282c6932e 100644 --- a/app/assets/javascripts/broadcast_notification.js +++ b/app/assets/javascripts/broadcast_notification.js @@ -1,4 +1,4 @@ -import Cookies from 'js-cookie'; +import { setCookie } from '~/lib/utils/common_utils'; const handleOnDismiss = ({ currentTarget }) => { currentTarget.removeEventListener('click', handleOnDismiss); @@ -6,7 +6,7 @@ const handleOnDismiss = ({ currentTarget }) => { dataset: { id, expireDate }, } = currentTarget; - Cookies.set(`hide_broadcast_message_${id}`, true, { expires: new Date(expireDate) }); + setCookie(`hide_broadcast_message_${id}`, true, { expires: new Date(expireDate) }); const notification = document.querySelector(`.js-broadcast-notification-${id}`); notification.parentNode.removeChild(notification); |