Skip to content

Commit

Permalink
Allow live location sharing for all users
Browse files Browse the repository at this point in the history
  • Loading branch information
MatMaul committed Apr 3, 2024
1 parent b7b1a9b commit ea097b7
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions room_access_rules/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,9 @@

ACCESS_RULES_TYPE = "im.vector.room.access_rules"

LOCATION_LIVE_SHARING_EVENT_TYPE = "m.beacon_info"
LOCATION_LIVE_SHARING_MSC_EVENT_TYPE = "org.matrix.msc3672.beacon_info"


class AccessRules:
DIRECT = "direct"
Expand Down Expand Up @@ -245,6 +248,9 @@ def _get_default_power_levels(user_id: str) -> Dict[str, Any]:
EventTypes.Tombstone: 100,
EventTypes.ServerACL: 100,
EventTypes.RoomEncryption: 100,
# We want normal users to be able to use live location sharing by default
LOCATION_LIVE_SHARING_EVENT_TYPE: 0,
LOCATION_LIVE_SHARING_MSC_EVENT_TYPE: 0,
},
"events_default": 0,
"state_default": 100, # Admins should be the only ones to perform other tasks
Expand Down

0 comments on commit ea097b7

Please sign in to comment.