Fixing log problems