Unverified Commit bc618eae authored by chrisgarrity's avatar chrisgarrity Committed by GitHub

Merge pull request #3647 from chrisgarrity/fix-set-lang-cookie

Set language cookie domain to allow for cross-domain cookies
parents da51161d ad2f0fa4
......@@ -21,7 +21,11 @@ class LanguageChooser extends React.Component {
]);
}
handleSetLanguage (name, value) {
jar.set('scratchlanguage', value);
let opts = {};
if (window.location.hostname !== 'localhost') {
opts = {domain: `.${window.location.hostname}`};
}
jar.set('scratchlanguage', value, opts);
window.location.reload();
}
render () {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment