diff --git a/appinfo/app.php b/appinfo/app.php
index ee9bcb5..a5838cd 100644
--- a/appinfo/app.php
+++ b/appinfo/app.php
@@ -21,4 +21,4 @@
*
*/
-$app = new \OCA\WorkflowScript\AppInfo\Application();
+$app = \OC::$server->query(\OCA\WorkflowScript\AppInfo\Application::class);
diff --git a/appinfo/info.xml b/appinfo/info.xml
index 9500f8d..55fddae 100644
--- a/appinfo/info.xml
+++ b/appinfo/info.xml
@@ -5,7 +5,7 @@
Workflow external scripts
Rule based processing of files through specified external scripts
Pass files on to external scripts depending on a defined set of rules.
- 1.3.0
+ 1.3.1
agpl
Arthur Schiwon
WorkflowScript
@@ -19,8 +19,7 @@
https://github.com/nextcloud/workflow_script
https://github.com/nextcloud/workflow_script/issues
https://github.com/nextcloud/workflow_script.git
- https://raw.githubusercontent.com/nextcloud/workflow_script/master/screenshots/settings.png
- https://raw.githubusercontent.com/nextcloud/workflow_script/master/screenshots/example_rule.png
+ https://raw.githubusercontent.com/nextcloud/workflow_script/master/screenshots/flow-ui.png
diff --git a/lib/Operation.php b/lib/Operation.php
index 3d4a9b0..72d0714 100644
--- a/lib/Operation.php
+++ b/lib/Operation.php
@@ -28,6 +28,7 @@
use OCA\WorkflowScript\BackgroundJobs\Launcher;
use OCP\BackgroundJob\IJobList;
use OCP\EventDispatcher\Event;
+use OCP\EventDispatcher\GenericEvent;
use OCP\Files\Folder;
use OCP\Files\InvalidPathException;
use OCP\Files\IRootFolder;
@@ -40,7 +41,7 @@
use OCP\WorkflowEngine\IManager;
use OCP\WorkflowEngine\IRuleMatcher;
use OCP\WorkflowEngine\ISpecificOperation;
-use Symfony\Component\EventDispatcher\GenericEvent;
+use Symfony\Component\EventDispatcher\GenericEvent as LegacyGenericEvent;
class Operation implements ISpecificOperation {
@@ -172,7 +173,9 @@ public function isAvailableForScope(int $scope): bool {
}
public function onEvent(string $eventName, Event $event, IRuleMatcher $ruleMatcher): void {
- if (!$event instanceof GenericEvent && !$event instanceof MapperEvent) {
+ if (!$event instanceof GenericEvent
+ && !$event instanceof LegacyGenericEvent
+ && !$event instanceof MapperEvent) {
return;
}
try {
@@ -202,7 +205,7 @@ public function onEvent(string $eventName, Event $event, IRuleMatcher $ruleMatch
return;
}
- $matches = $ruleMatcher->getMatchingOperations(Operation::class, false);
+ $matches = $ruleMatcher->getFlows(false);
foreach ($matches as $match) {
$command = $this->buildCommand($match['operation'], $node, $eventName, $extra);
$args = ['command' => $command];
diff --git a/screenshots/example_rule-small.png b/screenshots/example_rule-small.png
deleted file mode 100644
index fdb0ba9..0000000
Binary files a/screenshots/example_rule-small.png and /dev/null differ
diff --git a/screenshots/example_rule.png b/screenshots/example_rule.png
deleted file mode 100644
index a02c3d9..0000000
Binary files a/screenshots/example_rule.png and /dev/null differ
diff --git a/screenshots/flow-ui.png b/screenshots/flow-ui.png
new file mode 100644
index 0000000..5db8be9
Binary files /dev/null and b/screenshots/flow-ui.png differ
diff --git a/screenshots/settings-small.png b/screenshots/settings-small.png
deleted file mode 100644
index 85e5ede..0000000
Binary files a/screenshots/settings-small.png and /dev/null differ
diff --git a/screenshots/settings.png b/screenshots/settings.png
deleted file mode 100644
index 09d84af..0000000
Binary files a/screenshots/settings.png and /dev/null differ