Skip to content

Commit

Permalink
Merge pull request #2258 from alphagov/fix-cookies-bug
Browse files Browse the repository at this point in the history
Fix crash on cookie setting
  • Loading branch information
maxgds authored Sep 2, 2020
2 parents 45ccba5 + 130254d commit 46330c3
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions app/assets/javascripts/global-bar-init.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@ var globalBarInit = {
},

getLatestCookie: function() {
if (!window.GOVUK.cookie('cookies_policy')) {
window.GOVUK.setDefaultConsentCookie()
}
var currentCookie = window.GOVUK.getCookie(GLOBAL_BAR_SEEN_COOKIE)

if (currentCookie == null) {
return currentCookie
} else {
return currentCookie
}
return currentCookie

},

urlBlockList: function() {
Expand Down

0 comments on commit 46330c3

Please sign in to comment.