aboutsummaryrefslogtreecommitdiff
path: root/lib/document-to-html.js
diff options
context:
space:
mode:
Diffstat (limited to 'lib/document-to-html.js')
-rw-r--r--lib/document-to-html.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/document-to-html.js b/lib/document-to-html.js
index e022946..6094803 100644
--- a/lib/document-to-html.js
+++ b/lib/document-to-html.js
@@ -193,7 +193,9 @@ function DocumentConversion(options, comments) {
function recoveringConvertImage(convertImage) {
return function(image, messages) {
- return convertImage(image, messages).caught(function(error) {
+ return promises.attempt(function() {
+ return convertImage(image, messages);
+ }).caught(function(error) {
messages.push(results.error(error));
return [];
});