Remove use of deprecated debug function