mirror of
https://github.com/linux-odyssey/linux-odyssey.git
synced 2026-11-06 03:20:13 +08:00
feat: add session expiry deletion script and scheduler
This commit is contained in:
1 parent
8e63284211
commit
22060070b9
8 files changed
+94
-3
No files matched your search
@@ -0,0 +1,12 @@
|
||||
import { removeExpired } from '../containers/expiryChecker.js'
|
||||
import connectDB from '../db.js'
|
||||
|
||||
connectDB()
|
||||
.then(removeExpired)
|
||||
.then(() => {
|
||||
process.exit(0)
|
||||
})
|
||||
.catch((err) => {
|
||||
console.error(err)
|
||||
process.exit(1)
|
||||
})
|
||||
Reference in new issue
Block a user