Fix wrong merge, and remove some extra debug messages.