-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
156 additions
and
119 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,37 +1,21 @@ | ||
const options = { | ||
maxKeys: 10, | ||
stdTTL: 60000 * 10 | ||
} | ||
|
||
const NodeCache = require("node-cache") | ||
const RemainingEndpointCache = new NodeCache(options) | ||
const KoreanbotsCache = new NodeCache(options) | ||
|
||
const botsdotjsOptions = { | ||
maxKeys: 10, | ||
stdTTL: 60000 * 5 | ||
} | ||
|
||
const queryCacheOptions = { | ||
maxKeys: 25, | ||
stdTTL: 60000 * 5 | ||
} | ||
|
||
const BotsCache = new NodeCache(botsdotjsOptions) | ||
const BotsdotjsRemainingPerEndpoint = new NodeCache({ | ||
maxKeys: 10, | ||
stdTTL: 60000 * 60 | ||
}) | ||
const SearchCache = new NodeCache(queryCacheOptions) | ||
const CategoryCache = new NodeCache(queryCacheOptions) | ||
const { Collection } = require("@discordjs/collection") | ||
const RemainingEndpointCache = new Collection() | ||
const KoreanbotsCache = new Collection() | ||
const BotsCache = new Collection() | ||
const BotsdotjsRemainingPerEndpoint = new Collection() | ||
const SearchCache = new Collection() | ||
const CategoryCache = new Collection() | ||
const WidgetsCache = new Collection() | ||
|
||
module.exports = { | ||
"index.js": { | ||
KoreanbotsCache, RemainingEndpointCache | ||
}, | ||
"bots.js": { | ||
BotsCache, BotsdotjsRemainingPerEndpoint, SearchCache, CategoryCache | ||
}, | ||
"widget.js": { | ||
WidgetsCache | ||
} | ||
} | ||
|
||
//내가 봐도 이건 좀 개판이네 | ||
This comment has been minimized.
Sorry, something went wrong. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
이거 뭐죠