events: Remove deprecated method NameEventContent::name

This commit is contained in:
Jonas Platte 2021-08-11 17:06:42 +02:00
parent 0d293dec70
commit 202fc5132a
No known key found for this signature in database
GPG Key ID: CC154DE0E30B7C67
2 changed files with 2 additions and 7 deletions

View File

@ -8,6 +8,7 @@ Breaking changes:
* Replace `InvalidEvent` by a more specific `FromStringError` for room name
validation
* Remove unused `FromStrError`
* Remove deprecated method `room::name::NameEventContent::name`
# 0.23.3

View File

@ -1,7 +1,7 @@
//! Types for the *m.room.name* event.
use ruma_events_macros::EventContent;
use ruma_identifiers::{RoomName, RoomNameBox};
use ruma_identifiers::RoomNameBox;
use serde::{Deserialize, Serialize};
use crate::StateEvent;
@ -24,12 +24,6 @@ impl NameEventContent {
pub fn new(name: Option<RoomNameBox>) -> Self {
Self { name }
}
/// The name of the room, if any.
#[deprecated = "You can access the name field directly."]
pub fn name(&self) -> Option<&RoomName> {
self.name.as_deref()
}
}
#[cfg(test)]