Fix Cache (URL to File could fail if no parent)
[nikiroo-utils.git] / src / be / nikiroo / utils / resources / Bundle.java
index 40177da6cbfc23050e4e266d65253fde52060f27..83069f90793bdc9baabce94e76ee4a21846e6951 100644 (file)
@@ -698,7 +698,7 @@ public class Bundle<E extends Enum<E>> {
                        if (snap instanceof Map) {
                                changeMap = (Map<String, String>) snap;
                        } else {
-                               throw new Error(
+                               throw new RuntimeException(
                                                "Restoring changes in a Bundle must be done on a changes snapshot, "
                                                                + "or NULL to discard current changes");
                        }
@@ -740,7 +740,7 @@ public class Bundle<E extends Enum<E>> {
                        if (file.exists()) {
                                break;
                        }
-                       
+
                        file = null;
                }