use setting for stale query
more references
and views
Merge pull request #11 from dimagi/cz

use setting for stale query