Move .m.rule.roomnotif before .m.rule.tombstone (#1421)

See https://github.com/matrix-org/matrix-spec/issues/1406 for the reasoning on
this. TL;DR: the spec has always been wrong here.
This commit is contained in:
Richard van der Hoff 2023-02-10 12:04:24 +00:00 committed by GitHub
parent ad94985754
commit 6b02e39308
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 33 additions and 32 deletions

View file

@ -0,0 +1 @@
Correct the order of the default override pushrules in the spec.

View file

@ -524,6 +524,38 @@ Definition:
}
```
**`.m.rule.roomnotif`**
Matches any message whose content is unencrypted and contains the text
`@room`, signifying the whole room should be notified of the event.
Definition:
```json
{
"rule_id": ".m.rule.roomnotif",
"default": true,
"enabled": true,
"conditions": [
{
"kind": "event_match",
"key": "content.body",
"pattern": "@room"
},
{
"kind": "sender_notification_permission",
"key": "room"
}
],
"actions": [
"notify",
{
"set_tweak": "highlight"
}
]
}
```
**<a name="mruletombstone"></a>`.m.rule.tombstone`**
Matches any state event whose type is `m.room.tombstone`. This is
@ -587,38 +619,6 @@ Definition:
}
```
**`.m.rule.roomnotif`**
Matches any message whose content is unencrypted and contains the text
`@room`, signifying the whole room should be notified of the event.
Definition:
```json
{
"rule_id": ".m.rule.roomnotif",
"default": true,
"enabled": true,
"conditions": [
{
"kind": "event_match",
"key": "content.body",
"pattern": "@room"
},
{
"kind": "sender_notification_permission",
"key": "room"
}
],
"actions": [
"notify",
{
"set_tweak": "highlight"
}
]
}
```
###### Default Content Rules
**`.m.rule.contains_user_name`**