Factor out check for viewing html