doc: change matrix.org/docs/spec links to spec.matrix.org

This commit is contained in:
Nashwan Azhari
2026-01-31 21:23:20 +02:00
committed by Benjamin Bouvier
parent 2f7887d607
commit cb9690ecba
6 changed files with 8 additions and 8 deletions

View File

@@ -12,7 +12,7 @@
// See the License for the specific language governing permissions and
// limitations under the License.
//! Media store and common types for [media content](https://matrix.org/docs/spec/client_server/r0.6.1#id66).
//! Media store and common types for [media content](https://spec.matrix.org/latest/client-server-api/#content-repository).
pub mod store;

View File

@@ -44,7 +44,7 @@ impl Room {
/// If you need a variant that's sync (but with the drawback that it returns
/// an `Option`), consider using [`Room::cached_display_name`].
///
/// [spec]: <https://matrix.org/docs/spec/client_server/latest#calculating-the-display-name-for-a-room>
/// [spec]: <https://spec.matrix.org/latest/client-server-api/#calculating-the-display-name-for-a-room>
pub async fn display_name(&self) -> StoreResult<RoomDisplayName> {
if let Some(name) = self.cached_display_name() {
Ok(name)
@@ -99,7 +99,7 @@ impl Room {
/// or [`Room::display_name`] (async, always returns a value), which should
/// be preferred in general.
///
/// [spec]: <https://matrix.org/docs/spec/client_server/latest#calculating-the-display-name-for-a-room>
/// [spec]: <https://spec.matrix.org/latest/client-server-api/#calculating-the-display-name-for-a-room>
pub(crate) async fn compute_display_name(&self) -> StoreResult<UpdatedRoomDisplayName> {
enum DisplayNameOrSummary {
Summary(RoomSummary),
@@ -407,7 +407,7 @@ pub struct RoomHero {
const NUM_HEROES: usize = 5;
/// The name of the room, either from the metadata or calculated
/// according to [matrix specification](https://matrix.org/docs/spec/client_server/latest#calculating-the-display-name-for-a-room)
/// according to [matrix specification](https://spec.matrix.org/latest/client-server-api/#calculating-the-display-name-for-a-room)
#[derive(Clone, Debug, Eq, PartialEq, Serialize, Deserialize)]
pub enum RoomDisplayName {
/// The room has been named explicitly as

View File

@@ -1097,7 +1097,7 @@ pub enum RoomEventDecryptionResult {
/// [end-to-end-encryption]: https://en.wikipedia.org/wiki/End-to-end_encryption
/// [homeserver]: https://spec.matrix.org/unstable/#architecture
/// [key-agreement protocol]: https://en.wikipedia.org/wiki/Key-agreement_protocol
/// [client-server specification]: https://matrix.org/docs/spec/client_server/
/// [client-server specification]: https://spec.matrix.org/latest/client-server-api
/// [forward secrecy]: https://en.wikipedia.org/wiki/Forward_secrecy
/// [replay attacks]: https://en.wikipedia.org/wiki/Replay_attack
/// [Tracking the device list for a user]: https://spec.matrix.org/unstable/client-server-api/#tracking-the-device-list-for-a-user

View File

@@ -79,7 +79,7 @@ pub fn calculate_commitment(public_key: Curve25519PublicKey, content: &StartCont
/// The spec defines 64 unique emojis, this function panics if the index is
/// bigger than 63.
///
/// [spec]: https://matrix.org/docs/spec/client_server/latest#sas-method-emoji
/// [spec]: https://spec.matrix.org/latest/client-server-api/#sas-method-emoji
fn emoji_from_index(index: u8) -> Emoji {
/*
This list was generated from the data in the spec [1] with the following command:

View File

@@ -2,7 +2,7 @@ A high-level, batteries-included [Matrix](https://matrix.org/) client library
written in Rust.
This crate seeks to be a general-purpose library for writing software using the
Matrix [Client-Server API](https://matrix.org/docs/spec/client_server/latest)
Matrix [Client-Server API](https://spec.matrix.org/latest/client-server-api/)
to communicate with a Matrix homeserver. If you're writing a typical Matrix
client or bot, this is likely the crate you need.

View File

@@ -17,7 +17,7 @@ struct UserProfile {
}
/// This function calls the GET profile endpoint
/// Spec: <https://matrix.org/docs/spec/client_server/r0.6.1#get-matrix-client-r0-profile-userid>
/// Spec: <https://spec.matrix.org/latest/client-server-api/#get_matrixclientv3profileuserid>
/// Ruma: <https://docs.rs/ruma-client-api/0.9.0/ruma_client_api/r0/profile/get_profile/index.html>
async fn get_profile(client: Client, mxid: &UserId) -> MatrixResult<UserProfile> {
// First construct the request you want to make