From 463a03112260ecf39818eac09905f41d8e84ced7 Mon Sep 17 00:00:00 2001 From: alecpl Date: Mon, 14 Dec 2009 08:52:33 +0000 Subject: - handle situation when 2nd argument of exec_hook() isn't an array (#1486364) --- program/include/rcube_plugin_api.php | 3 +++ 1 file changed, 3 insertions(+) (limited to 'program') diff --git a/program/include/rcube_plugin_api.php b/program/include/rcube_plugin_api.php index 75f1cc478..6a26df8e4 100644 --- a/program/include/rcube_plugin_api.php +++ b/program/include/rcube_plugin_api.php @@ -181,6 +181,9 @@ class rcube_plugin_api */ public function exec_hook($hook, $args = array()) { + if (!is_array($args)) + $args = array('arg' => $args); + $args += array('abort' => false); $this->active_hook = $hook; -- cgit v1.2.3