Commit 59127a72 authored by wudizhanche1000's avatar wudizhanche1000

Fix: 可以重复创建Library的问题

parent 5758b394
......@@ -126,10 +126,16 @@ export class AppDetailComponent implements OnInit {
} catch (e) {
this.installOption.installLibrary = this.settingsService.getDefaultLibrary().path;
alert("无法创建指定目录");
} finally {
let index = this.availableLibraries.findIndex((l) => {
return l === volume
});
this.availableLibraries.splice(index, 1);
}
} else {
this.settingsService.setDefaultLibrary({path: this.installOption.installLibrary, "default": true})
}
this.installOption.installLibrary = this.settingsService.getDefaultLibrary().path;
}
selectDir() {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment