Remove unnecessary crate:: prefixes.

This commit is contained in:
Jimmy Cuadra 2019-07-13 06:12:45 -07:00
parent ebc6579d81
commit b003699048
6 changed files with 7 additions and 7 deletions

View File

@ -5,7 +5,7 @@ use std::collections::HashMap;
use ruma_identifiers::UserId; use ruma_identifiers::UserId;
use serde::{ser::SerializeStruct, Deserialize, Serialize, Serializer}; use serde::{ser::SerializeStruct, Deserialize, Serialize, Serializer};
use crate::{Empty, Event, EventType}; use crate::{Empty, Event, EventType, InvalidEvent};
/// A list of users to ignore. /// A list of users to ignore.
#[derive(Clone, Debug, PartialEq)] #[derive(Clone, Debug, PartialEq)]
@ -23,7 +23,7 @@ pub struct IgnoredUserListEventContent {
impl IgnoredUserListEvent { impl IgnoredUserListEvent {
/// Attempt to create `Self` from parsing a string of JSON data. /// Attempt to create `Self` from parsing a string of JSON data.
pub fn from_str(json: &str) -> Result<Self, crate::InvalidEvent> { pub fn from_str(json: &str) -> Result<Self, InvalidEvent> {
let raw = serde_json::from_str::<raw::IgnoredUserListEvent>(json)?; let raw = serde_json::from_str::<raw::IgnoredUserListEvent>(json)?;
Ok(Self { Ok(Self {

View File

@ -35,7 +35,7 @@ pub enum StartEventContent {
} }
impl FromStr for StartEvent { impl FromStr for StartEvent {
type Err = crate::InvalidEvent; type Err = InvalidEvent;
/// Attempt to create `Self` from parsing a string of JSON data. /// Attempt to create `Self` from parsing a string of JSON data.
fn from_str(json: &str) -> Result<Self, Self::Err> { fn from_str(json: &str) -> Result<Self, Self::Err> {

View File

@ -77,7 +77,7 @@ pub enum MessageEventContent {
} }
impl FromStr for MessageEvent { impl FromStr for MessageEvent {
type Err = crate::InvalidEvent; type Err = InvalidEvent;
/// Attempt to create `Self` from parsing a string of JSON data. /// Attempt to create `Self` from parsing a string of JSON data.
fn from_str(json: &str) -> Result<Self, Self::Err> { fn from_str(json: &str) -> Result<Self, Self::Err> {

View File

@ -49,7 +49,7 @@ pub struct NameEventContent {
} }
impl FromStr for NameEvent { impl FromStr for NameEvent {
type Err = crate::InvalidEvent; type Err = InvalidEvent;
/// Attempt to create `Self` from parsing a string of JSON data. /// Attempt to create `Self` from parsing a string of JSON data.
fn from_str(json: &str) -> Result<Self, Self::Err> { fn from_str(json: &str) -> Result<Self, Self::Err> {

View File

@ -88,7 +88,7 @@ pub struct PowerLevelsEventContent {
} }
impl FromStr for PowerLevelsEvent { impl FromStr for PowerLevelsEvent {
type Err = crate::InvalidEvent; type Err = InvalidEvent;
/// Attempt to create `Self` from parsing a string of JSON data. /// Attempt to create `Self` from parsing a string of JSON data.
fn from_str(json: &str) -> Result<Self, Self::Err> { fn from_str(json: &str) -> Result<Self, Self::Err> {

View File

@ -70,7 +70,7 @@ pub struct ServerAclEventContent {
} }
impl FromStr for ServerAclEvent { impl FromStr for ServerAclEvent {
type Err = crate::InvalidEvent; type Err = InvalidEvent;
/// Attempt to create `Self` from parsing a string of JSON data. /// Attempt to create `Self` from parsing a string of JSON data.
fn from_str(json: &str) -> Result<Self, Self::Err> { fn from_str(json: &str) -> Result<Self, Self::Err> {