Cleaned up loggin