Add missing logic condition