refactor: cache the token as long as possible
During installation, the salt is generated and remains constant unless the user re-installs the FreshRSS instance.
This commit is contained in:
parent
651e06aa25
commit
63e38a5fa7
@ -27,7 +27,7 @@ async function login(widget, service) {
|
||||
|
||||
try {
|
||||
const [, token] = data.toString().split("\n").find(line => line.startsWith("Auth=")).split("=")
|
||||
cache.put(`${sessionTokenCacheKey}.${service}`, token, 30 * 60 * 1000); // 30m
|
||||
cache.put(`${sessionTokenCacheKey}.${service}`, token);
|
||||
return { token };
|
||||
} catch (e) {
|
||||
logger.error("Unable to login to FreshRSS API: %s", e);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user