Moving debug statement to an appropriate area