diff --git a/server/lib/classes/plugin_webserver_base.inc.php b/server/lib/classes/plugin_webserver_base.inc.php index 8f18db74918cc983cfa5694ddb82795e5872c743..bbe9f6718f5620fcbea4606de260924276c5b452 100644 --- a/server/lib/classes/plugin_webserver_base.inc.php +++ b/server/lib/classes/plugin_webserver_base.inc.php @@ -30,6 +30,8 @@ EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. class plugin_webserver_base { + private $action = ''; + public function registerEvents($server_type = 'apache') { global $app; @@ -522,10 +524,12 @@ class plugin_webserver_base { $app->log('Removed AWStats config file: '.$awstats_conf_dir.'/awstats.'.$data['old']['domain'].'.conf', LOGLEVEL_DEBUG); } } - - public function eventUpdate($event_name, $data, $server_type = 'apache') { + + public function eventUpdate($event_name, $data, $action, $server_type = 'apache') { global $app, $conf; + $this->action = $action; + if($server_type === 'nginx') { //* Check if the apache plugin is enabled if(@is_link('/usr/local/ispconfig/server/plugins-enabled/apache2_plugin.inc.php')) { diff --git a/server/plugins-available/apache2_plugin.inc.php b/server/plugins-available/apache2_plugin.inc.php index 2af63d270360690ad6e65888006d2c5736f8b071..ccb7a81e0137245ee00e8822ed8413ddb8a88025 100644 --- a/server/plugins-available/apache2_plugin.inc.php +++ b/server/plugins-available/apache2_plugin.inc.php @@ -98,7 +98,7 @@ class apache2_plugin { if($this->action != 'insert') $this->action = 'update'; - $app->plugin_webserver_base->eventUpdate($event_name, $data, 'apache'); + $app->plugin_webserver_base->eventUpdate($event_name, $data, $this->action, 'apache'); //* Unset action to clean it for next processed vhost. $this->action = '';