Fix for noRetriesLeft of job query