Adding debug function.