summaryrefslogtreecommitdiffstats
path: root/apps/files_sharing/lib/Controller
diff options
context:
space:
mode:
authorMax <max@nextcloud.com>2022-07-25 20:17:15 +0200
committerVincent Petry (Rebase PR Action) <PVince81@users.noreply.github.com>2022-08-25 21:59:19 +0000
commit99aa938452a089e66fe993c98a4292fcfa9caa15 (patch)
treee3f7eae822e3c610a11c580294dcefe011c18db3 /apps/files_sharing/lib/Controller
parent38d0419f14ad70dbd82ef18946846b8ce3ea1682 (diff)
downloadnextcloud-server-99aa938452a089e66fe993c98a4292fcfa9caa15.tar.gz
nextcloud-server-99aa938452a089e66fe993c98a4292fcfa9caa15.zip
feature: first take on using the viewer to render single file shares
Signed-off-by: Max <max@nextcloud.com>
Diffstat (limited to 'apps/files_sharing/lib/Controller')
-rw-r--r--apps/files_sharing/lib/Controller/ShareController.php9
1 files changed, 4 insertions, 5 deletions
diff --git a/apps/files_sharing/lib/Controller/ShareController.php b/apps/files_sharing/lib/Controller/ShareController.php
index a12878e6de2..87f143facd0 100644
--- a/apps/files_sharing/lib/Controller/ShareController.php
+++ b/apps/files_sharing/lib/Controller/ShareController.php
@@ -523,13 +523,12 @@ class ShareController extends AuthPublicShareController {
\OCP\Util::addScript('files', 'filelist');
\OCP\Util::addScript('files', 'keyboardshortcuts');
\OCP\Util::addScript('files', 'operationprogressbar');
-
- // Load Viewer scripts
- if (class_exists(LoadViewer::class)) {
- $this->eventDispatcher->dispatchTyped(new LoadViewer());
- }
}
+ // Load Viewer scripts
+ if (class_exists(LoadViewer::class)) {
+ $this->eventDispatcher->dispatchTyped(new LoadViewer());
+ }
// OpenGraph Support: http://ogp.me/
\OCP\Util::addHeader('meta', ['property' => "og:title", 'content' => $shareTmpl['filename']]);
\OCP\Util::addHeader('meta', ['property' => "og:description", 'content' => $this->defaults->getName() . ($this->defaults->getSlogan() !== '' ? ' - ' . $this->defaults->getSlogan() : '')]);