added debug
Merge pull request #63 from tobozo/apply-product-refactor

added debug