Adjusted IsActive logic