Null safety for event titles
This commit is contained in:
parent
10826e79b2
commit
732cc7cc95
|
@ -162,7 +162,7 @@ class ClpEvent implements Event {
|
||||||
|
|
||||||
factory ClpEvent.fromJson(Map<String, dynamic> json) {
|
factory ClpEvent.fromJson(Map<String, dynamic> json) {
|
||||||
return ClpEvent(
|
return ClpEvent(
|
||||||
title: json["title"],
|
title: json["title"] ?? "",
|
||||||
startTime: DateTime.parse(json["date"] + " " + json["start"]),
|
startTime: DateTime.parse(json["date"] + " " + json["start"]),
|
||||||
endTime: DateTime.parse(json["date"] + " " + json["end"]),
|
endTime: DateTime.parse(json["date"] + " " + json["end"]),
|
||||||
location: json["location"],
|
location: json["location"],
|
||||||
|
|
Loading…
Reference in New Issue