Some cleaning up and debug information.