This commit is contained in:
@@ -19,6 +19,13 @@ if (!process.env.STORAGE || process.env.STORAGE?.toLowerCase() === JSON_KEY) {
|
||||
throw Error("Nepodporovaná hodnota proměnné STORAGE: " + process.env.STORAGE + ", podporované jsou 'json' nebo 'redis'");
|
||||
}
|
||||
|
||||
(async () => {
|
||||
if (storage.initialize) {
|
||||
await storage.initialize();
|
||||
}
|
||||
})();
|
||||
|
||||
|
||||
export default function getStorage(): StorageInterface {
|
||||
return storage;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user