mirror of
https://github.com/matrix-org/matrix-spec
synced 2026-03-26 13:04:10 +01:00
Apply suggestions from code review
Co-authored-by: Richard van der Hoff <1389908+richvdh@users.noreply.github.com>
This commit is contained in:
parent
290fa16ca3
commit
1653b43cde
|
|
@ -1 +1 @@
|
|||
Clarifies the historical handling of non-integer power levels.
|
||||
Clarify the historical handling of non-integer power levels.
|
||||
|
|
@ -2,7 +2,7 @@
|
|||
toc_hide: true
|
||||
---
|
||||
|
||||
##### Power levels accepted as strings
|
||||
##### `m.room.power_levels` events accept values as strings
|
||||
|
||||
In order to maintain backwards compatibility with early implementations,
|
||||
power levels can optionally be represented in string format instead of
|
||||
|
|
@ -10,7 +10,7 @@ integer format. A homeserver must be prepared to deal with this by parsing
|
|||
the power level from a string. In these cases, the following formatting of the
|
||||
power level string is allowed:
|
||||
|
||||
* a single Base10 integer, no float values or decimal points, optionally with
|
||||
* a single base 10 integer, no float values or decimal points, optionally with
|
||||
any number of leading zeroes (`"100"`, `"000100"`);
|
||||
* optionally with any number of leading or trailing whitespace characters (`" 100 "`,
|
||||
`" 00100 "`);
|
||||
|
|
@ -19,6 +19,6 @@ power level string is allowed:
|
|||
`"-100"`).
|
||||
|
||||
{{% boxes/note %}}
|
||||
The integer represented by the string must still be within the `[-2^53, 2^53)`
|
||||
The integer represented by the string must still be within the `[-(2**53)+1, (2**53)-1]`
|
||||
range accepted by normal, non-string, power level values.
|
||||
{{% /boxes/note %}}
|
||||
|
|
|
|||
|
|
@ -41,12 +41,12 @@ use cases should reference.
|
|||
{{% /boxes/warning %}}
|
||||
|
||||
[Room version 7](/rooms/v7) added "knocking" and [room version 8](/rooms/v8)
|
||||
added "join restrictions" (refined by [room version 9](/rooms/v9)) - both allow
|
||||
prospective members an avenue to join, however both could not be used at the
|
||||
same time due to how the join rules work. This room version adds a new
|
||||
added "join restrictions" (refined by [room version 9](/rooms/v9)) — both allow
|
||||
prospective members an avenue to join, however it was not possible to use
|
||||
the two mechanisms together. This room version adds a new
|
||||
`knock_restricted` join rule as a mix of the two behaviours, allowing a user to
|
||||
join the room if they meet either the `restricted` join rule criteria or the
|
||||
`knock` join rule criteria - whichever function they're attempting to use.
|
||||
`knock` join rule criteria.
|
||||
|
||||
This room version additionally requires that values in the power levels event
|
||||
be integers and not string representations, unlike other room versions.
|
||||
|
|
@ -63,7 +63,7 @@ for details on the current event format.
|
|||
While this room version does not change the event format specifically, some
|
||||
deprecated behaviours are strictly no longer supported.
|
||||
|
||||
##### Power levels must be integers
|
||||
##### Values in `m.room.power_levels` events must be integers
|
||||
|
||||
In other room versions, such as [v9](/rooms/v9/#power-levels-accepted-as-strings),
|
||||
power levels could be represented as strings for backwards compatibility.
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ Clients which implement the redaction algorithm locally should refer to the
|
|||
|
||||
### Redactions
|
||||
|
||||
{{% added-in this=true %}} `m.room.member` now keep `join_authorised_via_users_server`
|
||||
{{% added-in this=true %}} `m.room.member` events now keep `join_authorised_via_users_server`
|
||||
in addition to other keys in `content` when being redacted.
|
||||
|
||||
{{% rver-fragment name="v9-redactions" %}}
|
||||
|
|
|
|||
Loading…
Reference in a new issue