public function callback_onAction() { try { $currentAction = $this->_wpFunctions->current_filter(); $args = func_get_args(); $eventName = "tubepress.wordpress.action.{$currentAction}"; if ($this->_loggingEnabled) { $this->_logDebug(sprintf('WordPress action <code>%s</code> invoked with <code>%d</code> argument(s). We will re-dispatch as <code>%s</code>.', $currentAction, count($args), $eventName)); } $this->_dispatch($eventName, $args); } catch (Exception $e) { $this->_logger->error($e->getMessage()); } }