Can anyone help me I'm trying to make sure these has checks are right. I may be having a problem with calories pooping out when the phone isn't connected to the watch. Here are the ones for when the app starts:
if (Toybox has :Weather) { _hasWeather = true; }
else { _hasWeather = false; }
if (System has :ConnectionInfo) { _hasConnectionInfo = true; }
else { _hasConnectionInfo = false; }
if (ActivityMonitor has :ActiveMinutes) { _hasActiveMinutes = true; }
else { _hasActiveMinutes = false; }
if (ActivityMonitor.Info has :floorsClimbed) { _hasFloors = true; }
else { _hasFloors = false; }
if (ActivityMonitor.Info has :calories) { _hasCalories = true; }
else { _hasCalories = false; }
After that, for the calories I use:
if (_hasCalories == false || ActivityMonitor.getInfo().calories == null) { return; }
Is this right? Thanks.