From: Simon Cross Date: Sat, 10 Sep 2016 11:55:29 +0000 (+0200) Subject: Return 0 for the direction if it is currently None. X-Git-Tag: tabakrolletjie-v1.0.0~114 X-Git-Url: https://git.ctpug.org.za/?p=tabakrolletjie.git;a=commitdiff_plain;h=821807f117dff841dd4f2249714dd8ae41e6a651 Return 0 for the direction if it is currently None. --- diff --git a/tabakrolletjie/rays.py b/tabakrolletjie/rays.py index 621ded6..11bfd33 100644 --- a/tabakrolletjie/rays.py +++ b/tabakrolletjie/rays.py @@ -148,6 +148,8 @@ class RayPolyManager(object): @property def direction(self): + if self._direction is None: + return 0 return self._direction.angle_degrees @direction.setter