mirror of
https://github.com/getpaseo/paseo.git
synced 2026-11-06 16:34:36 +00:00
fix(plugins): invoke cleanup before replacement setup
This commit is contained in:
@@ -103,10 +103,7 @@ export class PluginRegistry {
|
||||
Object.assign(installation, evaluated);
|
||||
const paseo = runtime.paseo;
|
||||
installation.cleanup = async () => {
|
||||
const results = await Promise.allSettled([
|
||||
paseo.dispose(),
|
||||
Promise.resolve().then(evaluated.cleanup),
|
||||
]);
|
||||
const results = await Promise.allSettled([paseo.dispose(), evaluated.cleanup()]);
|
||||
const failures = results.filter((result) => result.status === "rejected");
|
||||
if (failures.length)
|
||||
throw new AggregateError(
|
||||
|
||||
Reference in New Issue
Block a user