Intrahealth fixes

In the PR fixes for cases:
http://manage.dimagi.com/default.asp?125601#708608
http://manage.dimagi.com/default.asp?124261#708886