Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/ONLYOFFICE/onlyoffice-nextcloud.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'appinfo/application.php')
-rw-r--r--appinfo/application.php9
1 files changed, 6 insertions, 3 deletions
diff --git a/appinfo/application.php b/appinfo/application.php
index 8b178c6..8e7375e 100644
--- a/appinfo/application.php
+++ b/appinfo/application.php
@@ -1,7 +1,7 @@
<?php
/**
*
- * (c) Copyright Ascensio System SIA 2019
+ * (c) Copyright Ascensio System SIA 2020
*
* This program is a free software product.
* You can redistribute it and/or modify it under the terms of the GNU Affero General Public License
@@ -80,7 +80,8 @@ class Application extends App {
$eventDispatcher->addListener("OCA\Files_Sharing::loadAdditionalScripts",
function() {
- if (!empty($this->appConfig->GetDocumentServerUrl()) && $this->appConfig->SettingsAreSuccessful()) {
+ if (!empty($this->appConfig->GetDocumentServerUrl())
+ && $this->appConfig->SettingsAreSuccessful()) {
Util::addScript("onlyoffice", "main");
Util::addStyle("onlyoffice", "main");
}
@@ -131,7 +132,9 @@ class Application extends App {
$eventDispatcher->addListener(RegisterDirectEditorEvent::class,
function (RegisterDirectEditorEvent $event) use ($container) {
- if (!empty($this->appConfig->GetDocumentServerUrl()) && $this->appConfig->SettingsAreSuccessful()) {
+ if (!empty($this->appConfig->GetDocumentServerUrl())
+ && $this->appConfig->SettingsAreSuccessful()
+ && $this->appConfig->isUserAllowedToUse()) {
$editor = $container->query("DirectEditor");
$event->register($editor);
}