adding debug ouput