fix(koplugin): properly refresh access token (#2384)

This commit is contained in:
Huang Xin
2025-11-02 11:50:54 +08:00
committed by GitHub
parent 984d5d198d
commit d54c752637
+1 -1
View File
@@ -122,7 +122,7 @@ end
function ReadestSync:tryRefreshToken()
if self.settings.refresh_token and self.settings.expires_at
and self.settings.expires_at < os.time() - self.settings.expires_in / 2 then
and self.settings.expires_at < os.time() + self.settings.expires_in / 2 then
local client = self:getSupabaseAuthClient()
client:refresh_token(self.settings.refresh_token, function(success, response)
if success then