Always use our own exception tree

This commit is contained in:
emeric
2018-07-26 10:26:49 +02:00
parent 853bcbe008
commit a31fb3c062
9 changed files with 27 additions and 20 deletions
+3 -2
View File
@@ -22,6 +22,7 @@
#include <Wt/WApplication.h>
#include <Wt/Http/Response.h>
#include "utils/Exception.hpp"
#include "utils/Logger.hpp"
#include "utils/Utils.hpp"
@@ -58,7 +59,7 @@ ImageResource::getDefaultCover(std::size_t size)
Image::Image image;
if (!image.load( Wt::WApplication::instance()->docRoot() + unknownCoverPath ))
throw std::runtime_error("Cannot read default cover file");
throw LmsException("Cannot read default cover file");
image.scale(size);
@@ -80,7 +81,7 @@ ImageResource::getDefaultArtistImage(std::size_t size)
Image::Image image;
if (!image.load( Wt::WApplication::instance()->docRoot() + unknownArtistImagePath))
throw std::runtime_error("Cannot read default artist image file");
throw LmsException("Cannot read default artist image file");
image.scale(size);