Share::registerBackend('file', File::class);
Share::registerBackend('folder', Folder::class, 'file');
-
- /**
- * Always add main sharing script
- */
- Util::addScript(self::APP_ID, 'main');
}
$dispatcher->addListener(ResourcesLoadAdditionalScriptsEvent::class, function () {
\OCP\Util::addScript('files_sharing', 'collaboration');
});
+ $dispatcher->addListener(\OCP\AppFramework\Http\Events\BeforeTemplateRenderedEvent::class, function () {
+ /**
+ * Always add main sharing script
+ */
+ Util::addScript(self::APP_ID, 'main');
+ });
// notifications api to accept incoming user shares
$dispatcher->addListener(ShareCreatedEvent::class, function (ShareCreatedEvent $event) {