Fix detachFromCondition

Was removing things from list during loop through elements ...