2024-05-05 12:55:34 -07:00
|
|
|
import { RateLimiterMemory } from "rate-limiter-flexible"
|
|
|
|
|
|
|
|
export const saveFileRL = new RateLimiterMemory({
|
2024-05-11 17:23:45 -07:00
|
|
|
points: 2,
|
2024-05-05 12:55:34 -07:00
|
|
|
duration: 1,
|
|
|
|
})
|
|
|
|
|
2024-05-05 12:58:45 -07:00
|
|
|
export const MAX_BODY_SIZE = 5 * 1024 * 1024
|
|
|
|
|
2024-05-05 12:55:34 -07:00
|
|
|
export const createFileRL = new RateLimiterMemory({
|
2024-05-11 17:23:45 -07:00
|
|
|
points: 1,
|
|
|
|
duration: 2,
|
2024-05-05 12:55:34 -07:00
|
|
|
})
|
|
|
|
|
|
|
|
export const renameFileRL = new RateLimiterMemory({
|
2024-05-11 17:23:45 -07:00
|
|
|
points: 1,
|
|
|
|
duration: 2,
|
2024-05-05 12:55:34 -07:00
|
|
|
})
|
|
|
|
|
|
|
|
export const deleteFileRL = new RateLimiterMemory({
|
2024-05-11 17:23:45 -07:00
|
|
|
points: 1,
|
|
|
|
duration: 2,
|
2024-05-05 12:55:34 -07:00
|
|
|
})
|
2024-05-11 17:23:45 -07:00
|
|
|
|
|
|
|
export const deleteFolderRL = new RateLimiterMemory({
|
|
|
|
points: 1,
|
|
|
|
duration: 2,
|
|
|
|
})
|