Refactored debugging related statements and documentation.