Fixing log errors