summaryrefslogtreecommitdiff
path: root/stsci/sphere/polygon.py
diff options
context:
space:
mode:
Diffstat (limited to 'stsci/sphere/polygon.py')
-rw-r--r--stsci/sphere/polygon.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/stsci/sphere/polygon.py b/stsci/sphere/polygon.py
index 0406402..f7c44be 100644
--- a/stsci/sphere/polygon.py
+++ b/stsci/sphere/polygon.py
@@ -133,6 +133,8 @@ class SphericalPolygon(object):
List of *ra* and *dec* in degrees corresponding
to `points`.
"""
+ if len(self.points) == 0:
+ return np.array([])
return vector.vector_to_radec(self.points[:,0], self.points[:,1],
self.points[:,2], degrees=True)