1
0
mirror of synced 2025-01-11 08:15:48 +00:00

fix clippy warnings

This commit is contained in:
al8n 2023-01-16 10:25:43 +08:00 committed by gusto
parent 6b9e9d653c
commit bf4bfba863
2 changed files with 2 additions and 2 deletions

View File

@ -7,7 +7,7 @@ use axum::{
extract::Query,
http::HeaderValue,
routing::{get, post},
Extension, Router,
Router,
};
use hyper::{
header::{CONTENT_TYPE, USER_AGENT},

View File

@ -542,7 +542,7 @@ impl<'de> Deserialize<'de> for Histogram {
// TODO: this implementation is not correct because we cannot set samples for histogram,
// need to wait prometheus support serde.
SerializableHistogramOpts::deserialize(deserializer).map(
|SerializableHistogramOpts { val, opts }| {
|SerializableHistogramOpts { val: _, opts }| {
let x = prometheus::Histogram::with_opts(opts.clone()).unwrap();
Self { val: x, opts }
},