store tokens in memory directly

This commit is contained in:
spencerwooo
2021-12-31 13:19:38 +08:00
parent 978c6d82f6
commit 3dde6ac73c
+7 -6
View File
@@ -3,15 +3,16 @@
import os from 'os'
import Keyv from 'keyv'
import { KeyvFile } from 'keyv-file'
// import { KeyvFile } from 'keyv-file'
console.log(`${os.tmpdir()}/od-auth-token.json`)
const kv = new Keyv({
store: new KeyvFile({
filename: `${os.tmpdir()}/od-auth-token.json`,
}),
})
// const kv = new Keyv({
// store: new KeyvFile({
// filename: `${os.tmpdir()}/od-auth-token.json`,
// }),
// })
const kv = new Keyv({})
export async function storeOdAuthTokens({
accessToken,