JD
Size: a a a
JD
I
JD
I
АШ
OS
OS
i
OS
i
i
i
i
const session = await options.store.get(key) || {}на
const session = await options.store.get(key) || await options.store.set(key)?
i
i
sessionConfig = {
store: {
get: key => Sessions.findOne({ where: { id: key } }),
set: (key, session) =>
Sessions.findOne({ where: { id: key } })
.then(s => s ? s.update(session) : Sessions.create({ id: key, ...session }))
}
}
bot.use(session(sessionConfig))
JD
const session = await options.store.get(key) || {}на
const session = await options.store.get(key) || await options.store.set(key)?
JD
JD
i