Some refactoring and simplification in TcInteract.occurCheck