fix updating default consumption when product doesn't have valid code

http://manage.dimagi.com/default.asp?124149
/r/p/product
Merge pull request #3942 from dimagi/case-124149

fix updating default consumption when product doesn't have valid code