summaryrefslogtreecommitdiffstats
path: root/apps/files_sharing/templates
diff options
context:
space:
mode:
authorJoas Schilling <nickvergessen@owncloud.com>2015-03-11 17:08:25 +0100
committerJoas Schilling <nickvergessen@owncloud.com>2015-03-16 12:44:10 +0100
commit4c4c0fa12066b9dace5d9689836fe4a70141a2d9 (patch)
tree65ac1c648c0fa48f4a5c79885e373375d7b94cfb /apps/files_sharing/templates
parent1075914f8ab8f5f4c20ab7f0b9ce35e9a9e2ffe1 (diff)
downloadnextcloud-server-4c4c0fa12066b9dace5d9689836fe4a70141a2d9.tar.gz
nextcloud-server-4c4c0fa12066b9dace5d9689836fe4a70141a2d9.zip
Use the PreviewManager where possible
Diffstat (limited to 'apps/files_sharing/templates')
-rw-r--r--apps/files_sharing/templates/public.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/apps/files_sharing/templates/public.php b/apps/files_sharing/templates/public.php
index 4ec4d264b31..26fee0b8694 100644
--- a/apps/files_sharing/templates/public.php
+++ b/apps/files_sharing/templates/public.php
@@ -20,10 +20,10 @@ OCP\Util::addScript('files', 'filelist');
OCP\Util::addscript('files', 'keyboardshortcuts');
$thumbSize=1024;
-$previewSupported = OC\Preview::isMimeSupported($_['mimetype']) ? 'true' : 'false';
+$previewSupported = \OC::$server->getPreviewManager()->isMimeSupported($_['mimetype']) ? 'true' : 'false';
?>
-<?php if ( \OC\Preview::isMimeSupported($_['mimetype'])): /* This enables preview images for links (e.g. on Facebook, Google+, ...)*/?>
+<?php if ($previewSupported === 'true'): /* This enables preview images for links (e.g. on Facebook, Google+, ...)*/?>
<link rel="image_src" href="<?php p(OCP\Util::linkToRoute( 'core_ajax_public_preview', array('x' => $thumbSize, 'y' => $thumbSize, 'file' => $_['directory_path'], 't' => $_['dirToken']))); ?>" />
<?php endif; ?>