Handle unhandled error; remove error handling in server-only function (error would never become visible to user)

This commit is contained in:
RandyTheSilly committed 2025-06-01 12:35:07 -04:00
1 parent 4dab9f2c93
commit 2e3be57e3e
3 files changed
+8 -13

No files matched your search

+4 -1
View File
@@ -37,7 +37,10 @@ func EntryRefresh(oldRCWPassphrase, newRCWPassphrase []byte, removeOldDir bool)
return errors.New("unable to refresh entries: \"" + global.EntryRoot + "-old\" already exists")
}
}
os.RemoveAll(global.EntryRoot + dirEnd)
err := os.RemoveAll(global.EntryRoot + dirEnd)
if err != nil {
return errors.New("unable to remove \"" + global.EntryRoot + dirEnd + "\": " + err.Error())
}
}
// create output directory structure (global.EntryRoot + "-new"/*)