Skip to content

Commit

Permalink
Remove obsolete utilities
Browse files Browse the repository at this point in the history
  • Loading branch information
piroor committed Mar 5, 2024
1 parent b2f18fe commit 2c53273
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 21 deletions.
1 change: 0 additions & 1 deletion background/background.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

import {
configs,
wait,
log,
} from '/common/common.js';

Expand Down
20 changes: 0 additions & 20 deletions common/common.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,26 +34,6 @@ export const configs = new Configs({
]
});

export async function wait(task = 0, timeout = 0) {
if (typeof task != 'function') {
timeout = task;
task = null;
}
return new Promise((resolve, _reject) => {
setTimeout(async () => {
if (task)
await task();
resolve();
}, timeout);
});
}

export function nextFrame() {
return new Promise((resolve, _reject) => {
window.requestAnimationFrame(resolve);
});
}

export function log(...args)
{
if (!configs.debug)
Expand Down

0 comments on commit 2c53273

Please sign in to comment.