From 38a90130ce425d531a804dff591df4a883de3154 Mon Sep 17 00:00:00 2001 From: Arthur Schiwon Date: Wed, 25 Apr 2018 15:22:28 +0200 Subject: move log constants to ILogger Signed-off-by: Arthur Schiwon --- lib/public/Util.php | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) (limited to 'lib/public/Util.php') diff --git a/lib/public/Util.php b/lib/public/Util.php index 9ffa55e2dfd..0e32d8473a5 100644 --- a/lib/public/Util.php +++ b/lib/public/Util.php @@ -57,11 +57,25 @@ namespace OCP; * @since 4.0.0 */ class Util { - // consts for Logging + /** + * @deprecated 14.0.0 use \OCP\ILogger::DEBUG + */ const DEBUG=0; + /** + * @deprecated 14.0.0 use \OCP\ILogger::INFO + */ const INFO=1; + /** + * @deprecated 14.0.0 use \OCP\ILogger::WARN + */ const WARN=2; + /** + * @deprecated 14.0.0 use \OCP\ILogger::ERROR + */ const ERROR=3; + /** + * @deprecated 14.0.0 use \OCP\ILogger::FATAL + */ const FATAL=4; /** \OCP\Share\IManager */ @@ -115,7 +129,7 @@ class Util { * @since ....0.0 - parameter $level was added in 7.0.0 * @deprecated 8.2.0 use logException of \OCP\ILogger */ - public static function logException( $app, \Exception $ex, $level = \OCP\Util::FATAL ) { + public static function logException( $app, \Exception $ex, $level = ILogger::FATAL) { \OC::$server->getLogger()->logException($ex, ['app' => $app]); } -- cgit v1.2.3