Disclosed are compounds of Formula (I) or a salt thereof, wherein: X is N W is: (i) —(CR3R3)1-4— (ii) —(CR3R3)x—Y—(CR3R3)y— Or (iii) —Y—(CR3R3)2—Y— and Y, R1, R2, R3, R5, R6, R8, x, and y are defined herein. Also disclosed are methods of using such compounds as modulators of TNFα, and pharmaceutical compositions comprising such compounds. These compounds are useful in treating inflammatory and autoimmune diseases.