aboutsummaryrefslogtreecommitdiff
path: root/src/support/dom
diff options
context:
space:
mode:
Diffstat (limited to 'src/support/dom')
-rw-r--r--src/support/dom/document_cache.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/support/dom/document_cache.cc b/src/support/dom/document_cache.cc
index f814559..1573af8 100644
--- a/src/support/dom/document_cache.cc
+++ b/src/support/dom/document_cache.cc
@@ -1,5 +1,7 @@
#include "document_cache.h"
+#include <stdexcept>
+
namespace InputXSLT {
DomDocumentCache::DomDocumentCache():
@@ -16,7 +18,7 @@ DomDocumentCache::item* DomDocumentCache::get(const std::string& key) {
if ( result.second ) {
return (*(result.first)).second.get();
} else {
- return nullptr;
+ throw std::out_of_range("failed to instantiate DomDocumentCache");
}
} else {
return (*itemIter).second.get();