Skip to content

Commit bb6cd93

Browse files
committed
Update of cookie settings.
1 parent aa115f0 commit bb6cd93

1 file changed

Lines changed: 15 additions & 0 deletions

File tree

docs/overrides/main.html

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,21 @@
77

88
{% block extrahead %}
99
{{ super() }}
10+
<script>
11+
(function () {
12+
var _get = Storage.prototype.getItem;
13+
var _set = Storage.prototype.setItem;
14+
var SHARED_KEY = '/__consent';
15+
Storage.prototype.getItem = function (key) {
16+
if (key && key.endsWith('.__consent')) return _get.call(this, SHARED_KEY);
17+
return _get.call(this, key);
18+
};
19+
Storage.prototype.setItem = function (key, value) {
20+
if (key && key.endsWith('.__consent')) { _set.call(this, SHARED_KEY, value); return; }
21+
_set.call(this, key, value);
22+
};
23+
})();
24+
</script>
1025
<link rel="stylesheet" href="https://www.utplsql.org/assets/topbar.css">
1126
<script src="https://www.utplsql.org/assets/topbar.js" defer></script>
1227
{% endblock %}

0 commit comments

Comments
 (0)