From 9d704183c7d626c0a2cdb44bbd981f26df7de9f4 Mon Sep 17 00:00:00 2001 From: Shish Date: Sun, 2 Feb 2020 17:00:33 +0000 Subject: [PATCH] actually do bulk actions from CLI --- ext/bulk_actions/main.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ext/bulk_actions/main.php b/ext/bulk_actions/main.php index 1516baae..d6b3e674 100644 --- a/ext/bulk_actions/main.php +++ b/ext/bulk_actions/main.php @@ -104,11 +104,11 @@ class BulkActions extends Extension if (count($event->args) < 2) { return; } - $query = $event->args[0]; - $items = $this->yield_search_results($event->args[1]); - $newEvent = new BulkActionEvent($event->args[0], $items); - var_dump($newEvent); - # send_event($newEvent); + $action = $event->args[0]; + $query = $event->args[1]; + $items = $this->yield_search_results($query); + log_info("bulk_actions", "Performing $action on {$event->args[1]}"); + send_event(new BulkActionEvent($event->args[0], $items)); } }