chore/remove openapi assertion for dart 2 (#2916)

* chore(server): patch dart openapi assertion 2

* removed usused file
This commit is contained in:
Alex 2023-06-22 13:00:07 -05:00 committed by GitHub
parent 4311d385fc
commit 751922990f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
93 changed files with 99 additions and 1102 deletions

View file

@ -69,17 +69,17 @@ class UpdateAssetDto {
if (this.isFavorite != null) {
json[r'isFavorite'] = this.isFavorite;
} else {
// json[r'isFavorite'] = null;
// json[r'isFavorite'] = null;
}
if (this.isArchived != null) {
json[r'isArchived'] = this.isArchived;
} else {
// json[r'isArchived'] = null;
// json[r'isArchived'] = null;
}
if (this.description != null) {
json[r'description'] = this.description;
} else {
// json[r'description'] = null;
// json[r'description'] = null;
}
return json;
}
@ -91,17 +91,6 @@ class UpdateAssetDto {
if (value is Map) {
final json = value.cast<String, dynamic>();
// Ensure that the map contains the required keys.
// Note 1: the values aren't checked for validity beyond being non-null.
// Note 2: this code is stripped in release mode!
assert(() {
requiredKeys.forEach((key) {
assert(json.containsKey(key), 'Required key "UpdateAssetDto[$key]" is missing from JSON.');
// assert(json[key] != null, 'Required key "UpdateAssetDto[$key]" has a null value in JSON.');
});
return true;
}());
return UpdateAssetDto(
tagIds: json[r'tagIds'] is Iterable
? (json[r'tagIds'] as Iterable).cast<String>().toList(growable: false)