Skip to content

Commit

Permalink
Merge pull request #3818 from nextcloud/enh/collaboration-event
Browse files Browse the repository at this point in the history
Move to OCP\Collaboration\Resources\LoadAdditionalScriptsEvent
  • Loading branch information
juliushaertl authored Jul 7, 2022
2 parents 02a6fa7 + 9e26af6 commit bebd157
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 7 deletions.
8 changes: 4 additions & 4 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions lib/Controller/PageController.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
use OCA\Files\Event\LoadSidebar;
use OCA\Viewer\Event\LoadViewer;
use OCP\AppFramework\Http\ContentSecurityPolicy;
use OCP\Collaboration\Resources\LoadAdditionalScriptsEvent as CollaborationResourcesEvent;
use OCP\EventDispatcher\IEventDispatcher;
use OCP\IConfig;
use OCP\IInitialStateService;
Expand Down Expand Up @@ -88,6 +89,7 @@ public function index() {
$this->initialState->provideInitialState(Application::APP_ID, 'config', $this->configService->getAll());

$this->eventDispatcher->dispatchTyped(new LoadSidebar());
$this->eventDispatcher->dispatchTyped(new CollaborationResourcesEvent());
if (class_exists(LoadViewer::class)) {
$this->eventDispatcher->dispatchTyped(new LoadViewer());
}
Expand Down
3 changes: 0 additions & 3 deletions templates/main.php
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,3 @@

OCP\Util::addStyle('deck', 'globalstyles');
OCP\Util::addScript('deck', 'deck-main');

\OCP\Server::get(\OC\EventDispatcher\SymfonyAdapter::class)
->dispatch('\OCP\Collaboration\Resources::loadAdditionalScripts');

0 comments on commit bebd157

Please sign in to comment.