Merge branch 'feature/null-safety' into persistence-nnbd

This commit is contained in:
Salvatore Giordano
2021-04-21 10:06:43 +02:00
committed by GitHub
33 changed files with 1246 additions and 1512 deletions
@@ -27,7 +27,7 @@ class ChannelModel {
createdAt = createdAt ?? DateTime.now(),
updatedAt = updatedAt ?? DateTime.now(),
assert(
cid != null || (id != null && type != null),
(cid != null && cid.contains(':')) || (id != null && type != null),
'provide either a cid or an id and type',
),
id = id ?? cid!.split(':')[1],