*: fix pedantry
This commit is contained in:
parent
dc63498a27
commit
f2c3dc3fa4
|
@ -168,7 +168,7 @@ impl Metric {
|
|||
MetricType::Ticker(Metric {
|
||||
variant: parts.iter().cloned().collect(),
|
||||
fields: fields
|
||||
.unwrap_or_else(|| vec![])
|
||||
.unwrap_or_default()
|
||||
.iter()
|
||||
.map(|(fieldname, fieldtype)| ((*fieldname).to_string(), (*fieldtype).to_string()))
|
||||
.collect(),
|
||||
|
@ -183,7 +183,7 @@ impl Metric {
|
|||
MetricType::Counter(Metric {
|
||||
variant: parts.iter().cloned().collect(),
|
||||
fields: fields
|
||||
.unwrap_or_else(|| vec![])
|
||||
.unwrap_or_default()
|
||||
.iter()
|
||||
.map(|(fieldname, fieldtype)| ((*fieldname).to_string(), (*fieldtype).to_string()))
|
||||
.collect(),
|
||||
|
|
|
@ -44,7 +44,7 @@ fn main() -> Result<(), Box<dyn Error>> {
|
|||
})?;
|
||||
|
||||
let queue_name = if cfg.runner.build_all_jobs != Some(true) {
|
||||
let queue_name = format!("build-inputs-{}", cfg.nix.system.clone());
|
||||
let queue_name = format!("build-inputs-{}", cfg.nix.system);
|
||||
chan.declare_queue(easyamqp::QueueConfig {
|
||||
queue: queue_name.clone(),
|
||||
passive: false,
|
||||
|
|
|
@ -39,7 +39,7 @@ fn main() -> Result<(), Box<dyn Error>> {
|
|||
let nix = cfg.nix();
|
||||
|
||||
let events = stats::RabbitMQ::from_lapin(
|
||||
&format!("{}-{}", cfg.runner.identity.clone(), cfg.nix.system.clone()),
|
||||
&format!("{}-{}", cfg.runner.identity, cfg.nix.system),
|
||||
task::block_on(conn.create_channel())?,
|
||||
);
|
||||
|
||||
|
|
|
@ -19,7 +19,7 @@ fn main() -> Result<(), Box<dyn Error>> {
|
|||
let mut chan = task::block_on(conn.create_channel())?;
|
||||
|
||||
let events = stats::RabbitMQ::from_lapin(
|
||||
&format!("{}-{}", cfg.runner.identity.clone(), cfg.nix.system.clone()),
|
||||
&format!("{}-{}", cfg.runner.identity, cfg.nix.system),
|
||||
task::block_on(conn.create_channel())?,
|
||||
);
|
||||
|
||||
|
|
|
@ -32,7 +32,7 @@ impl BuildJob {
|
|||
statusreport: Option<ExchangeQueue>,
|
||||
request_id: String,
|
||||
) -> BuildJob {
|
||||
let logbackrk = format!("{}.{}", repo.full_name.clone(), pr.number,).to_lowercase();
|
||||
let logbackrk = format!("{}.{}", repo.full_name, pr.number).to_lowercase();
|
||||
|
||||
BuildJob {
|
||||
repo,
|
||||
|
|
Loading…
Reference in a new issue