Don't log if global logging is disabled.