blob: 923b8ee3b10e0626a8b8c3af23fd43f45664ae7a (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
using System.Text.Json.Serialization;
namespace LibMatrix.LegacyEvents.EventTypes.Spec.State;
[LegacyMatrixEvent(EventName = EventId)]
public class RoomGuestAccessLegacyEventContent : LegacyEventContent {
public const string EventId = "m.room.guest_access";
[JsonPropertyName("guest_access")]
public string GuestAccess { get; set; }
[JsonIgnore]
public bool IsGuestAccessEnabled {
get => GuestAccess == "can_join";
set => GuestAccess = value ? "can_join" : "forbidden";
}
}
|