mirror of
https://github.com/Significant-Gravitas/AutoGPT.git
synced 2026-04-08 03:00:28 -04:00
Fix issue with decoding metrics JSON
This commit is contained in:
@@ -49,7 +49,9 @@ class Metrics {
|
||||
difficulty: json['difficulty'] ?? "",
|
||||
success: json['success'],
|
||||
attempted: json['attempted'],
|
||||
successPercentage: json['success_percentage'].toDouble() ?? 0.0,
|
||||
successPercentage: (json['success_percentage'] != null)
|
||||
? json['success_percentage'].toDouble()
|
||||
: 0.0,
|
||||
cost: json['cost'] ?? "",
|
||||
runTime: json['run_time'] ?? "",
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user