diff --git a/crates/ruma-common/Cargo.toml b/crates/ruma-common/Cargo.toml index 3b58b520..88d02e8d 100644 --- a/crates/ruma-common/Cargo.toml +++ b/crates/ruma-common/Cargo.toml @@ -46,7 +46,6 @@ unstable-msc3554 = ["unstable-msc1767"] base64 = "0.13.0" bytes = "1.0.1" criterion = { version = "0.3.3", optional = true } -either = { version = "1.6.1", optional = true } form_urlencoded = "1.0.0" http = { version = "0.2.2", optional = true } indexmap = { version = "1.6.2", features = ["serde-1"] } diff --git a/crates/ruma-common/src/identifiers/room_or_room_alias_id.rs b/crates/ruma-common/src/identifiers/room_or_room_alias_id.rs index ddcf2f8a..3a1e60ae 100644 --- a/crates/ruma-common/src/identifiers/room_or_room_alias_id.rs +++ b/crates/ruma-common/src/identifiers/room_or_room_alias_id.rs @@ -51,18 +51,6 @@ impl RoomOrAliasId { self.variant() == Variant::RoomAliasId } - /// Turn this `RoomOrAliasId` into `Either` - #[cfg(feature = "either")] - pub fn into_either(self: Box) -> either::Either, Box> { - let variant = self.variant(); - let boxed_str = self.into_owned(); - - match variant { - Variant::RoomId => either::Either::Left(RoomId::from_box(boxed_str)), - Variant::RoomAliasId => either::Either::Right(RoomAliasId::from_box(boxed_str)), - } - } - fn colon_idx(&self) -> usize { self.as_str().find(':').unwrap() } diff --git a/crates/ruma/Cargo.toml b/crates/ruma/Cargo.toml index 2944b53d..a1b08597 100644 --- a/crates/ruma/Cargo.toml +++ b/crates/ruma/Cargo.toml @@ -54,7 +54,6 @@ push-gateway-api-s = ["api", "ruma-push-gateway-api/server"] push-gateway-api = ["push-gateway-api-c", "push-gateway-api-s"] # Convenience features -either = ["ruma-common/either"] rand = ["ruma-common/rand"] markdown = ["ruma-common/markdown"] @@ -71,7 +70,6 @@ full = [ "federation-api", "identity-service-api", "push-gateway-api", - "either", "rand", "markdown", ]