Fix condition (last thread was always ommited)