Modify ConvexHull sample to check for SpatialReference rather than Extent.