Removed unused headers. Corrected debug logs.