consolidated addClass lines