summaryrefslogtreecommitdiffstats
path: root/lib/Migration
diff options
context:
space:
mode:
authorMaxence Lange <maxence@artificial-owl.com>2018-12-19 00:13:33 -0100
committerMaxence Lange <maxence@artificial-owl.com>2018-12-19 00:13:33 -0100
commit37a889d9780314af06c373c7e605e9606238f34e (patch)
treece001b3d0b8bba7a6313a6570884b8a01d88e492 /lib/Migration
parent47c658c32b712277f9330801085c4dd288dbe742 (diff)
Merge branch 'master' into framework-import-process+activity
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
Diffstat (limited to 'lib/Migration')
-rw-r--r--lib/Migration/CheckInstallation.php80
1 files changed, 80 insertions, 0 deletions
diff --git a/lib/Migration/CheckInstallation.php b/lib/Migration/CheckInstallation.php
new file mode 100644
index 00000000..a3b58915
--- /dev/null
+++ b/lib/Migration/CheckInstallation.php
@@ -0,0 +1,80 @@
+<?php
+declare(strict_types=1);
+
+
+/**
+ * Nextcloud - Social Support
+ *
+ * This file is licensed under the Affero General Public License version 3 or
+ * later. See the COPYING file.
+ *
+ * @author Maxence Lange <maxence@artificial-owl.com>
+ * @copyright 2018, Maxence Lange <maxence@artificial-owl.com>
+ * @license GNU AGPL version 3 or any later version
+ *
+ * This program is free software: you can redistribute it and/or modify
+ * it under the terms of the GNU Affero General Public License as
+ * published by the Free Software Foundation, either version 3 of the
+ * License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU Affero General Public License for more details.
+ *
+ * You should have received a copy of the GNU Affero General Public License
+ * along with this program. If not, see <http://www.gnu.org/licenses/>.
+ *
+ */
+
+
+namespace OCA\Social\Migration;
+
+
+use OCA\Social\Service\CheckService;
+use OCP\Migration\IOutput;
+use OCP\Migration\IRepairStep;
+
+
+/**
+ * Class CheckInstallation
+ *
+ * @package OCA\Social\Migration
+ */
+class CheckInstallation implements IRepairStep {
+
+
+ /** @var CheckService */
+ protected $checkService;
+
+
+ /**
+ * CheckInstallation constructor.
+ *
+ * @param CheckService $checkService
+ */
+ public function __construct(CheckService $checkService) {
+ $this->checkService = $checkService;
+ }
+
+
+ /**
+ * Returns the step's name
+ *
+ * @return string
+ * @since 9.1.0
+ */
+ public function getName() {
+ return 'Check the installation of the Social app.';
+ }
+
+
+ /**
+ * @param IOutput $output
+ */
+ public function run(IOutput $output) {
+ $this->checkService->checkInstallationStatus();
+ }
+
+
+}