Your problem is not with IF...ENDIF but rather with INGROUP().

There are a gazzillion posts that discuss INGROUP(). A good place to start is to flush the token cache. This is explained in the manual.
_________________________
Give a man a fish and he will be back for more. Slap him with a fish and he will go away forever.