if (!empty(\Civi::$statics[__CLASS__]['userFrameworkLogging'])) {
// should call $config->userSystem->logger($message) here - but I got a situation where userSystem was not an object - not sure why
if ($config->userSystem->is_drupal and function_exists('watchdog')) {
- watchdog('civicrm', '%message', ['%message' => $message], WATCHDOG_DEBUG);
+ watchdog('civicrm', '%message', ['%message' => $message], isset($priority) ? $priority : WATCHDOG_DEBUG);
}
}