Added API error handling

Added null checks for getTempHigh and getTempLow used to generate
snapshots.