Skip to content

Commit 5608851

Browse files
fix: log warning and fallback to local storage when default EntityFileStorage is not found
1 parent a34d561 commit 5608851

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

extensions/entity-files/sources/core/src/main/java/tools/dynamia/modules/entityfile/service/impl/EntityFileServiceImpl.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -346,8 +346,8 @@ private EntityFileStorage getCurrentStorage() {
346346
String storageId = appParams.getValue(DEFAULT_STORAGE, LocalEntityFileStorage.ID);
347347
EntityFileStorage storage = findStorage(storageId);
348348
if (storage == null) {
349-
throw new EntityFileException("No default " + EntityFileStorage.class
350-
.getSimpleName() + " configured");
349+
logger.warn("No default " + EntityFileStorage.class.getSimpleName() + " found with id: " + storageId + ". Using local storage.");
350+
return Containers.get().findObject(LocalEntityFileStorage.class);
351351
}
352352
return storage;
353353
}

0 commit comments

Comments
 (0)