Minor fixes for logging