-
- /**
- * @brief Logs the given message at the given log level
- *
- * @param string $msg
- * @param int $level
- *
- * @deprecated since 2019.03 Use Logger::debug() Logger::info() , ... instead
- */
- public static function log($msg, $level = self::INFO)
- {
- if (!isset(self::$logger)) {
- return;
- }
-
- $loglevel = self::mapPSR3Level($level);
-
- $stamp1 = microtime(true);
- self::$logger->log($loglevel, $msg);
- self::getApp()->saveTimestamp($stamp1, "file");
- }
-
- /**
- * @brief An alternative logger for development.
- * Works largely as log() but allows developers
- * to isolate particular elements they are targetting
- * personally without background noise
- *
- * @param string $msg
- * @param string $level
- */
- public static function devLog($msg, $level = LogLevel::DEBUG)
- {
- if (!isset(self::$logger)) {
- return;
- }
-
- $stamp1 = microtime(true);
- self::$devLogger->log($level, $msg);
- self::getApp()->saveTimestamp($stamp1, "file");
- }