more correct fallback for unknown join conditions
This commit is contained in:
parent
b390dbbbe1
commit
fcfe4eed1e
1 changed files with 5 additions and 0 deletions
|
|
@ -21,6 +21,8 @@ sealed class JoinRulesContent extends Content with _$JoinRulesContent {
|
|||
@JsonSerializable()
|
||||
class const AllowCondition({
|
||||
final String? roomId,
|
||||
|
||||
@JsonKey(unknownEnumValue: AllowConditionType.unknown)
|
||||
required final AllowConditionType type,
|
||||
}) with _$AllowCondition {
|
||||
Map<String, Object?> toJson() => _$AllowConditionToJson(this);
|
||||
|
|
@ -32,4 +34,5 @@ class const AllowCondition({
|
|||
enum AllowConditionType {
|
||||
@JsonValue("m.room_membership")
|
||||
membership,
|
||||
unknown,
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue