feat: log issues with removing files

This commit is contained in:
Jose Diaz-Gonzalez
2020-03-10 22:21:27 -04:00
parent b881be1cfe
commit 62a361cbe0

View File

@@ -32,9 +32,14 @@ func TriggerPostDelete(appName string) error {
imageRepo := common.GetAppImageRepo(appName)
// remove contents for apps that are symlinks to other folders
os.RemoveAll(fmt.Sprintf("%v/", common.AppRoot(appName)))
if err := os.RemoveAll(fmt.Sprintf("%v/", common.AppRoot(appName))); err != nil {
common.LogWarn(err.Error())
}
// then remove the folder and/or the symlink
os.RemoveAll(common.AppRoot(appName))
if err := os.RemoveAll(common.AppRoot(appName)); err != nil {
common.LogWarn(err.Error())
}
imagesByAppLabel, err := listImagesByAppLabel(appName)
if err != nil {