allow uninstall even if app is not installed (bad state)
This commit is contained in:
parent
c8680f0bd2
commit
06fcaeb13a
2 changed files with 8 additions and 1 deletions
|
@ -1,6 +1,8 @@
|
|||
{
|
||||
"name": "Anonaddy",
|
||||
"port": 8084,
|
||||
"available": false,
|
||||
"categories": ["utilities"],
|
||||
"id": "anonaddy",
|
||||
"description": "",
|
||||
"short_desc": "Anonymous email forwarding",
|
||||
|
|
|
@ -134,7 +134,12 @@ const uninstallApp = async (id: string): Promise<App> => {
|
|||
|
||||
await App.update({ id }, { status: AppStatusEnum.UNINSTALLING });
|
||||
// Run script
|
||||
await runAppScript(['uninstall', id]);
|
||||
try {
|
||||
await runAppScript(['uninstall', id]);
|
||||
} catch (e) {
|
||||
console.log(e);
|
||||
}
|
||||
|
||||
await App.delete({ id });
|
||||
|
||||
return { id, status: AppStatusEnum.MISSING, config: {} } as App;
|
||||
|
|
Loading…
Add table
Reference in a new issue