X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/fb9afd32db582cda6cebfbb84c93c0aa2b4bbb03..a1ff77ec56969346ecb5ba978879f5a96f166735:/app/assets/javascripts/index.js?ds=sidebyside diff --git a/app/assets/javascripts/index.js b/app/assets/javascripts/index.js index 782b9363c..5f84fb056 100644 --- a/app/assets/javascripts/index.js +++ b/app/assets/javascripts/index.js @@ -171,18 +171,18 @@ $(document).ready(function () { $('.welcome .close-wrap').on('click', function() { $('.welcome').hide(); - $.cookie('_osm_welcome', 'hide', { expires: expiry }); + $.cookie('_osm_welcome', 'hide', { expires: expiry, path: '/' }); }); var bannerExpiry = new Date(); - expiry.setYear(expiry.getFullYear() + 1); + bannerExpiry.setYear(bannerExpiry.getFullYear() + 1); $('#banner .close-wrap').on('click', function(e) { var cookieId = e.target.id; $('#banner').hide(); e.preventDefault(); if (cookieId) { - $.cookie(cookieId, 'hide', { expires: bannerExpiry }); + $.cookie(cookieId, 'hide', { expires: bannerExpiry, path: '/' }); } });