summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorGeorg Ehrke <developer@georgehrke.com>2014-09-21 17:30:29 +0200
committerGeorg Ehrke <developer@georgehrke.com>2014-09-22 00:48:01 +0200
commit2068eaf16b7a7722fb13093ce09f6663f160bd6f (patch)
treecd2c59dabd6768ca733a0c00fc1ece53efdf94c2 /lib
parent645e7a0c9e1939816bdf592a966618c6d02e729a (diff)
downloadnextcloud-server-2068eaf16b7a7722fb13093ce09f6663f160bd6f.tar.gz
nextcloud-server-2068eaf16b7a7722fb13093ce09f6663f160bd6f.zip
make sure preview prop is instanceof OC_Image before using it in showPreview
Diffstat (limited to 'lib')
-rwxr-xr-xlib/private/preview.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/private/preview.php b/lib/private/preview.php
index 6172519c7d1..9006a2e8cbe 100755
--- a/lib/private/preview.php
+++ b/lib/private/preview.php
@@ -537,7 +537,9 @@ class Preview {
if (is_null($this->preview)) {
$this->getPreview();
}
- $this->preview->show($mimeType);
+ if ($this->preview instanceof \OC_Image) {
+ $this->preview->show($mimeType);
+ }
}
/**