]> source.dussan.org Git - nextcloud-server.git/commitdiff
Load the Template class in case it's not loaded 926/head
authorJoas Schilling <coding@schilljs.com>
Thu, 18 Aug 2016 10:00:59 +0000 (12:00 +0200)
committerJoas Schilling <coding@schilljs.com>
Thu, 18 Aug 2016 10:01:59 +0000 (12:01 +0200)
apps/workflowengine/lib/AppInfo/Application.php

index b5e769d01d72c5e922e2d349e6dda92ed3cf0c32..e968b40612f0d74592c61215f62408048c162271 100644 (file)
@@ -21,9 +21,6 @@
 
 namespace OCA\WorkflowEngine\AppInfo;
 
-use OCP\Util;
-use OCP\WorkflowEngine\RegisterCheckEvent;
-
 class Application extends \OCP\AppFramework\App {
 
        public function __construct() {
@@ -41,6 +38,11 @@ class Application extends \OCP\AppFramework\App {
                $dispatcher->addListener(
                        'OCP\WorkflowEngine::loadAdditionalSettingScripts',
                        function() {
+                               if (!function_exists('style')) {
+                                       // This is hacky, but we need to load the template class
+                                       class_exists('OCP\Template', true);
+                               }
+
                                style('workflowengine', [
                                        'admin',
                                ]);