aboutsummaryrefslogtreecommitdiffstats
path: root/Zotlabs/Thumbs/Epubthumb.php
diff options
context:
space:
mode:
Diffstat (limited to 'Zotlabs/Thumbs/Epubthumb.php')
-rw-r--r--Zotlabs/Thumbs/Epubthumb.php7
1 files changed, 6 insertions, 1 deletions
diff --git a/Zotlabs/Thumbs/Epubthumb.php b/Zotlabs/Thumbs/Epubthumb.php
index 22f1a5e8f..6ebbd8933 100644
--- a/Zotlabs/Thumbs/Epubthumb.php
+++ b/Zotlabs/Thumbs/Epubthumb.php
@@ -30,9 +30,14 @@ class Epubthumb {
*/
function Thumb($attach, $preview_style, $height = 300, $width = 300) {
+ $file = dbunescbin($attach['content']);
+ if (!$file) {
+ return;
+ }
+
$photo = false;
- $ep = new \EPub(dbunescbin($attach['content']));
+ $ep = new \EPub($file);
$data = $ep->Cover();
if($data['found']) {