Description
In EarMojo.java:881, the return value of File.delete() is ignored:
If the file cannot be deleted (e.g., locked by another process, permission denied), the failure goes undetected. In incremental builds, stale resources can remain behind.
Expected behavior
Check the return value and log a warning:
if (!resourceFile.delete()) {
getLog().warn("Failed to delete outdated resource: " + resourceFile);
}
Description
In
EarMojo.java:881, the return value ofFile.delete()is ignored:If the file cannot be deleted (e.g., locked by another process, permission denied), the failure goes undetected. In incremental builds, stale resources can remain behind.
Expected behavior
Check the return value and log a warning: