modified to spot conflicts