diff --git a/src/ideascale/mod.rs b/src/ideascale/mod.rs index 96de27c0..ea7f69ba 100644 --- a/src/ideascale/mod.rs +++ b/src/ideascale/mod.rs @@ -86,7 +86,7 @@ pub async fn fetch_all(fund: usize, api_token: String) -> Result = ['*', '-', '/'].iter().copied().collect(); @@ -97,7 +96,7 @@ pub struct CleanString(#[serde(deserialize_with = "deserialize_clean_string")] S impl Funnel { pub fn is_community(&self) -> bool { - self.title.contains("Challenge Setting") + self.title.as_ref().contains("Challenge Setting") } } @@ -107,10 +106,8 @@ impl ToString for CleanString { } } -impl Deref for CleanString { - type Target = String; - - fn deref(&self) -> &Self::Target { +impl AsRef for CleanString { + fn as_ref(&self) -> &str { &self.0 } }