refactor: ♻️ Fix code smell

This commit is contained in:
Axel Olausson Holtenäs 2022-12-13 15:04:16 +01:00
parent c33a9c345e
commit e2eeec8b97

View file

@ -11,7 +11,6 @@ export const start = async (client: Client) => {
const jobNames = await checkDirectory("schedules");
if (!jobNames) return logger.warn("⏰ No available jobs found");
await Promise.all(
jobNames.map(async (jobName) => {
const job: IJob = await import(`../../schedules/${jobName}`);
@ -19,6 +18,5 @@ export const start = async (client: Client) => {
logger.verbose(`⏰ Performed the job "${jobName}"`);
await job.execute(client);
});
})
);
});
};