misc cleanup in wisepill code
Merge pull request #1604 from dimagi/wisepill-cleanup

misc cleanup in wisepill code