Cleaned up not_if logic

Change-Id: Ib1859da3f76a17bd41f036ea63ca8c218486d77f