Note: Remove the asserts

We actually do quite often create notes without anything, and then later
fill them up. Lets just setup a bad default for the created.
This commit is contained in:
Vishesh Handa
2019-01-23 12:08:06 +01:00
parent a29a102667
commit dfd5d6f6d2

View File

@ -12,10 +12,9 @@ class Note implements Comparable {
Map<String, dynamic> extraProperties = new Map<String, dynamic>();
Note({this.created, this.body, this.fileName, this.extraProperties}) {
assert(this.created != null);
assert(this.body != null);
assert(this.fileName != null);
if (created == null) {
created = DateTime(0, 0, 0, 0, 0, 0, 0, 0);
}
if (extraProperties == null) {
extraProperties = new Map<String, dynamic>();
}