refactor: Remove global dispatcher config

This commit is contained in:
Luan
2024-10-27 10:27:38 -03:00
parent 0081e11ebc
commit 01057f6dfa

View File

@@ -6,9 +6,7 @@ import {
Response,
Headers,
FormData,
File,
setGlobalDispatcher,
Agent
File
} from 'undici';
import type { ICache } from '../types/Cache.js';
import { Platform } from '../utils/Utils.js';
@@ -29,12 +27,6 @@ const __dirname__ = is_cjs ? __dirname : path.dirname(fileURLToPath(meta_url));
const { homepage, version, bugs } = $INLINE_JSON('../../package.json');
const repo_url = homepage?.split('#')[0];
setGlobalDispatcher(new Agent({
connect: {
timeout: 60_000
}
}));
class Cache implements ICache {
#persistent_directory: string;
#persistent: boolean;