fixes #1831 adding expiration check to working query
Merge pull request #1832 from dotCMS/issue-1831-timemachine-working-expired

fixes #1831 adding expiration check to working query