fix: plex role optional id
This commit is contained in:
@@ -4,7 +4,7 @@ part 'plex_role.g.dart';
|
||||
|
||||
@JsonSerializable()
|
||||
class PlexRole {
|
||||
final int id;
|
||||
final int? id;
|
||||
final String? filter;
|
||||
final String tag;
|
||||
final String? tagKey;
|
||||
@@ -13,7 +13,7 @@ class PlexRole {
|
||||
final int? count;
|
||||
|
||||
PlexRole({
|
||||
required this.id,
|
||||
this.id,
|
||||
this.filter,
|
||||
required this.tag,
|
||||
this.tagKey,
|
||||
|
||||
@@ -7,7 +7,7 @@ part of 'plex_role.dart';
|
||||
// **************************************************************************
|
||||
|
||||
PlexRole _$PlexRoleFromJson(Map<String, dynamic> json) => PlexRole(
|
||||
id: (json['id'] as num).toInt(),
|
||||
id: (json['id'] as num?)?.toInt(),
|
||||
filter: json['filter'] as String?,
|
||||
tag: json['tag'] as String,
|
||||
tagKey: json['tagKey'] as String?,
|
||||
|
||||
Reference in New Issue
Block a user