Do not crash if there are no sorted job in the 2nd run

Authored by mutlaqja on Oct 24 2018, 7:05 PM.