Added protected method to log
Removed some commented out code