mirror of
https://github.com/bknd-io/bknd/
synced 2026-08-02 08:06:00 +00:00
4e718a063d
Removed various commented-out code and replaced direct `console.log` and `console.warn` usage across the codebase with `$console` from "core" for standardized logging. Also adjusted linting rules in biome.json to enable warnings for `console.log` usage.
18 lines
448 B
TypeScript
18 lines
448 B
TypeScript
import { Type } from "core/utils";
|
|
import { Task } from "../Task";
|
|
import { $console } from "core";
|
|
|
|
export class LogTask extends Task<typeof LogTask.schema> {
|
|
type = "log";
|
|
|
|
static override schema = Type.Object({
|
|
delay: Type.Number({ default: 10 }),
|
|
});
|
|
|
|
async execute() {
|
|
await new Promise((resolve) => setTimeout(resolve, this.params.delay));
|
|
$console.log(`[DONE] LogTask: ${this.name}`);
|
|
return true;
|
|
}
|
|
}
|