diff --git a/src/app/common.php b/src/app/common.php index 1cbeadd9b..ff1056f6a 100644 --- a/src/app/common.php +++ b/src/app/common.php @@ -633,6 +633,17 @@ function addon_is_exit($name, $site_id = 0) } /***************************************************LuckySaaS系统函数***************************************************/ + +/** + * 检测事件是否存在 + * @param string $event + * @return bool + */ +function hasEvent($event) +{ + return Event::hasListener($event); +} + /** * 处理事件 *