toJson method
Implementation
Map<String, dynamic> toJson() {
final json = <String, dynamic>{};
json[r'_id'] = this.id;
if (this.userId != null) {
json[r'userId'] = this.userId;
} else {
json[r'userId'] = null;
}
json[r'banType'] = this.banType;
if (this.email != null) {
json[r'email'] = this.email;
} else {
json[r'email'] = null;
}
if (this.ipHash != null) {
json[r'ipHash'] = this.ipHash;
} else {
json[r'ipHash'] = null;
}
if (this.bannedUntil != null) {
json[r'bannedUntil'] = this.bannedUntil!.toUtc().toIso8601String();
} else {
json[r'bannedUntil'] = null;
}
json[r'hasEmailWildcard'] = this.hasEmailWildcard;
if (this.banReason != null) {
json[r'banReason'] = this.banReason;
} else {
json[r'banReason'] = null;
}
json[r'matches'] = this.matches;
return json;
}