StepData.initialData constructor
StepData.initialData(
- StepCountWithTimestamp stepCount
Implementation
StepData.initialData(StepCountWithTimestamp stepCount)
: previousDate =
formatDate(stepCount.timeStamp.subtract(const Duration(days: 1))),
previousStepCount = stepCount.stepsFromBoot,
todayDate = formatDate(stepCount.timeStamp),
todayStepCount = stepCount.stepsFromBoot,
bootCount = stepCount.bootCount,
stack = [],
lastSavedAt = stepCount.timeStamp.toIso8601String(),
previousStepCountSavedAt = null;