Fix logger method
Comments and formatting