KeyRecord.fromJson constructor
Implementation
factory KeyRecord.fromJson(Map<String, dynamic> json) {
final best = json['b'];
final lastAt = json['t'];
return KeyRecord(
bestPercent: best is num ? best.round().clamp(0, 100) : 0,
lastAt: lastAt is num ? lastAt.round() : 0,
);
}