Update gpsd.js

Added undefined check in stop