clippy all codes (#1214)

1. clippy code
2. add fmt and clippy check in ci
This commit is contained in:
Sijie.Sun
2025-08-10 22:56:41 +08:00
committed by GitHub
parent 0087ac3ffc
commit e43537939a
144 changed files with 1475 additions and 1531 deletions
+6 -3
View File
@@ -1,5 +1,8 @@
use crate::{
common::config::ConfigLoader, launcher::ConfigSource, instance_manager::NetworkInstanceManager, proto::{
common::config::ConfigLoader,
instance_manager::NetworkInstanceManager,
launcher::ConfigSource,
proto::{
rpc_types::{self, controller::BaseController},
web::{
CollectNetworkInfoRequest, CollectNetworkInfoResponse, DeleteNetworkInstanceRequest,
@@ -8,7 +11,7 @@ use crate::{
RetainNetworkInstanceResponse, RunNetworkInstanceRequest, RunNetworkInstanceResponse,
ValidateConfigRequest, ValidateConfigResponse, WebClientService,
},
}
},
};
pub struct Controller {
@@ -108,7 +111,7 @@ impl WebClientService for Controller {
if !include_inst_ids.is_empty() {
let mut to_remove = Vec::new();
for (k, _) in ret.map.iter() {
if !include_inst_ids.contains(&k) {
if !include_inst_ids.contains(k) {
to_remove.push(k.clone());
}
}