mirror of
https://github.com/wassname/talk.git
synced 2026-07-03 00:53:00 +08:00
Merge pull request #1232 from coralproject/expiry-fix
Expiry Parsing Bug
This commit is contained in:
@@ -72,8 +72,10 @@ class SharedCacheDataLoader extends DataLoader {
|
||||
constructor(prefix, expiry, batchLoadFn, options) {
|
||||
super(SharedCacheDataLoader.batchLoadFn(prefix, expiry, batchLoadFn), options);
|
||||
|
||||
// Expiry is provided as a number in ms, we're using commands optimized for
|
||||
// seconds, so convert this to seconds.
|
||||
this._expiry = Math.floor(expiry / 1000);
|
||||
this._prefix = prefix;
|
||||
this._expiry = expiry;
|
||||
this._keyFunc = SharedCacheDataLoader.keyFunc(this._prefix);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user