Browse Source

Add domain parameter to theme cookie

merge-requests/64/head
Bauke 6 years ago
committed by Deimos
parent
commit
b9142a0452
  1. 3
      tildes/static/js/behaviors/theme-selector.js

3
tildes/static/js/behaviors/theme-selector.js

@ -14,7 +14,8 @@ $.onmount('[data-js-theme-selector]', function() {
// persist the new theme for the user in their cookie // persist the new theme for the user in their cookie
document.cookie = 'theme=' + new_theme + ';' + document.cookie = 'theme=' + new_theme + ';' +
'path=/;max-age=315360000;secure';
'path=/;max-age=315360000;secure;domain=' +
document.location.hostname;
// remove any theme classes currently on the body // remove any theme classes currently on the body
$body = $('body').first(); $body = $('body').first();

Loading…
Cancel
Save