You've already forked AstralRinth
forked from didirus/AstralRinth
chore(clippy): enable and fix many stricter lints (#3783)
* chore(clippy): enable and fix many stricter lints These ensure that the codebase uses more idiomatic, performant, and concise language constructions. * chore: make non-Clippy compiler warnings also deny by default
This commit is contained in:
committed by
GitHub
parent
301967d204
commit
f84f8c1c2b
@@ -18,6 +18,7 @@ use actix_web::{HttpRequest, HttpResponse, get, patch, post, web};
|
||||
use serde::Deserialize;
|
||||
use sqlx::PgPool;
|
||||
use std::collections::HashMap;
|
||||
use std::fmt::Write;
|
||||
use std::net::Ipv4Addr;
|
||||
use std::sync::Arc;
|
||||
use tracing::info;
|
||||
@@ -221,9 +222,11 @@ pub async fn delphi_result_ingest(
|
||||
|
||||
for (issue, trace) in &body.issues {
|
||||
for (path, code) in trace {
|
||||
header.push_str(&format!(
|
||||
write!(
|
||||
&mut header,
|
||||
"\n issue {issue} found at file {path}: \n ```\n{code}\n```"
|
||||
));
|
||||
)
|
||||
.unwrap();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -244,12 +247,15 @@ pub async fn delphi_result_ingest(
|
||||
|
||||
for (issue, trace) in &body.issues {
|
||||
for path in trace.keys() {
|
||||
thread_header
|
||||
.push_str(&format!("\n\n- issue {issue} found at file {path}"));
|
||||
write!(
|
||||
&mut thread_header,
|
||||
"\n\n- issue {issue} found at file {path}"
|
||||
)
|
||||
.unwrap();
|
||||
}
|
||||
|
||||
if trace.is_empty() {
|
||||
thread_header.push_str(&format!("\n\n- issue {issue} found",));
|
||||
write!(&mut thread_header, "\n\n- issue {issue} found").unwrap();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user