small method refactor so it can be reused
Merge pull request #123 from dimagi/cz

small method refactor so it can be reused