Skip to content

Commit

Permalink
prevent image none
Browse files Browse the repository at this point in the history
  • Loading branch information
MateoLostanlen committed Nov 10, 2024
1 parent eeb2ac5 commit 13c4535
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pyroengine/sensors.py
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,8 @@ def move_in_seconds(self, s: float, operation: str = "Right", speed: int = 20, s
self.move_camera("Stop")
time.sleep(1)
im = self.capture()
im.save(save_path)
if im is not None:
im.save(save_path)

def get_ptz_preset(self):
"""
Expand Down

0 comments on commit 13c4535

Please sign in to comment.