Fix for logging