]> Untitled Git - lemmy.git/blobdiff - crates/api/src/lib.rs
Sanitize html (#3708)
[lemmy.git] / crates / api / src / lib.rs
index 988dac27ab4085f95c30f216eba42343d88d336e..b297f503f6f9d4abc2115255a55e8ca567bd5fff 100644 (file)
@@ -60,7 +60,7 @@ pub(crate) fn captcha_as_wav_base64(captcha: &Captcha) -> Result<String, LemmyEr
   Ok(base64.encode(output_buffer.into_inner()))
 }
 
-/// Check size of report and remove whitespace
+/// Check size of report
 pub(crate) fn check_report_reason(reason: &str, local_site: &LocalSite) -> Result<(), LemmyError> {
   let slur_regex = &local_site_to_slur_regex(local_site);
 
@@ -76,6 +76,9 @@ pub(crate) fn check_report_reason(reason: &str, local_site: &LocalSite) -> Resul
 
 #[cfg(test)]
 mod tests {
+  #![allow(clippy::unwrap_used)]
+  #![allow(clippy::indexing_slicing)]
+
   use lemmy_api_common::utils::check_validator_time;
   use lemmy_db_schema::{
     source::{