This commit is contained in:
andreyflat 2025-08-19 03:23:29 +08:00
parent d42935c4b9
commit 23a105fc15

View file

@ -442,17 +442,19 @@ const videoObserver = new IntersectionObserver((entries, observer) => {
</script>
<script>
(function() {
const secret = "flat_secret_123"; // тот же SECRET_KEY, что в Netlify env
const url = "/.netlify/functions/privateViewLogger"
+ "?key=" + encodeURIComponent(secret)
+ "&path=" + encodeURIComponent(location.pathname);
(function () {
const secret = "flat_secret_123";
const url = "/.netlify/functions/privateViewLogger"
+ "?key=" + encodeURIComponent(secret)
+ "&path=" + encodeURIComponent(location.pathname);
fetch(url, { method: "POST", keepalive: true })
.catch(() => {}); // игнор ошибок
})();
fetch(url, { cache: "no-store" })
.then(r => r.text().then(t => console.log("logger:", r.status, t)))
.catch(e => console.log("logger error:", e));
})();
</script>
<button id="scrollToTopBtn" title="Rewind">&#8679;</button>
<script>