added case for first avail machine not having any avail at all