fix task manager wait(), ID 0 is now null

An ID with index of 0 and version of 0 is now treated as a null value ID.