Added debug print statements.