1 // For license of this file, see <project-root-folder>/LICENSE.md.
2 
3 #include "exceptions/networkexception.h"
4 
5 #include "network-web/networkfactory.h"
6 
NetworkException(QNetworkReply::NetworkError error,const QString & message)7 NetworkException::NetworkException(QNetworkReply::NetworkError error, const QString& message)
8   : ApplicationException(message.simplified().isEmpty()
9                          ? NetworkFactory::networkErrorText(error)
10                          : message), m_networkError(error) {}
11 
networkError() const12 QNetworkReply::NetworkError NetworkException::networkError() const {
13   return m_networkError;
14 }
15