Added debugging output to the wrong method