Fixed hanging if work duration is 0