fix + error message
This commit is contained in:
1 parent
a9c9542966
commit
7022eab3f1
1 file changed
+2
-2
@@ -21,8 +21,8 @@ public class ImageDao implements Dao<Image> {
|
|||||||
public ImageDao() {
|
public ImageDao() {
|
||||||
try {
|
try {
|
||||||
final var folderPath = new ClassPathResource("images");
|
final var folderPath = new ClassPathResource("images");
|
||||||
if (folderPath.exists())
|
if (!folderPath.exists())
|
||||||
throw new ImageResourceMissingException("folderPath is null");
|
throw new ImageResourceMissingException("folder images doesn't not exsit");
|
||||||
final var folder = folderPath.getFile();
|
final var folder = folderPath.getFile();
|
||||||
getAllImages(folder);
|
getAllImages(folder);
|
||||||
} catch (final Exception e) {
|
} catch (final Exception e) {
|
||||||
|
|||||||
Reference in new issue
Block a user