mirror of
https://github.com/GitJournal/GitJournal.git
synced 2025-06-29 02:07:39 +08:00
Note: Make sure extraProperties is always initialized
This commit is contained in:
@ -11,7 +11,11 @@ class Note implements Comparable {
|
|||||||
|
|
||||||
Map<String, dynamic> extraProperties = new Map<String, dynamic>();
|
Map<String, dynamic> extraProperties = new Map<String, dynamic>();
|
||||||
|
|
||||||
Note({this.created, this.body, this.id, this.extraProperties});
|
Note({this.created, this.body, this.id, this.extraProperties}) {
|
||||||
|
if (extraProperties == null) {
|
||||||
|
extraProperties = new Map<String, dynamic>();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
factory Note.fromJson(Map<String, dynamic> json) {
|
factory Note.fromJson(Map<String, dynamic> json) {
|
||||||
String id;
|
String id;
|
||||||
|
Reference in New Issue
Block a user