Comment debug code and minor bug fix