mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
ui: update resource loader
This commit is contained in:
1 parent
0726dba492
commit
258a677e4f
7 files changed
+34
-36
No files matched your search
@@ -73,7 +73,9 @@ export class Loader {
|
||||
const original = plugin.apply;
|
||||
const apply = (...args) => {
|
||||
const start = Date.now();
|
||||
const result = Promise.resolve(original(...args)).catch((e) => logger.error(e));
|
||||
const result = Promise.resolve()
|
||||
.then(() => original(...args))
|
||||
.catch((e) => logger.error(e));
|
||||
Promise.race([
|
||||
result,
|
||||
new Promise((resolve) => {
|
||||
|
||||
Reference in new issue
Block a user