Skip to content

Commit

Permalink
Merge pull request #3 from tchapgouv/allow-live-location-sharing
Browse files Browse the repository at this point in the history
Allow live location sharing for all users
  • Loading branch information
MatMaul authored May 3, 2024
2 parents a0d040f + ea097b7 commit 498a4cf
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 @@ -250,6 +253,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 498a4cf

Please sign in to comment.