Changed _ASTROPY_SETUP_ checking as per @iguananaut's suggestion in #922