Added some print statements for debug