need to invert logic getting flag from PAT