diff --git a/CHANGELOG.md b/CHANGELOG.md index 14c1b5db..b3d2042e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,7 +7,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [Unreleased] -- Nothing worth mentioning yet. +### Fixed + +- A bug where Session data did not refresh after 24 hours ## [0.36.7] - 2025-05-04 diff --git a/playlet-lib/src/components/Services/Innertube/SessionData.bs b/playlet-lib/src/components/Services/Innertube/SessionData.bs index 3bd29fae..dc8f8978 100644 --- a/playlet-lib/src/components/Services/Innertube/SessionData.bs +++ b/playlet-lib/src/components/Services/Innertube/SessionData.bs @@ -9,7 +9,7 @@ import "pkg:/source/utils/TimeUtils.bs" namespace Innertube const SESSION_DATA_VERSION = 1 - const INNERTUBE_VISITOR_DATA_LIFESPAN = 1000 * 60 * 60 * 24 + const INNERTUBE_VISITOR_DATA_LIFESPAN_SECONDS = 60 * 60 * 24 function GetSessionData() as object sessionData = ReadSessionDataFromRegistry() @@ -81,7 +81,7 @@ namespace Innertube timestamp = sessionData.timestamp nowSeconds = TimeUtils.Now().AsSeconds() - if nowSeconds - timestamp > INNERTUBE_VISITOR_DATA_LIFESPAN + if nowSeconds - timestamp > INNERTUBE_VISITOR_DATA_LIFESPAN_SECONDS RegistryUtils.Delete(RegistryUtils.INNERTUBE_SESSION_DATA) return invalid end if