Skip to content

Commit 8b943ad

Browse files
authored
chore(http): remove obsolete const lint allow (#26127)
1 parent 6ba30ff commit 8b943ad

1 file changed

Lines changed: 2 additions & 4 deletions

File tree

‎src/http.rs‎

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -754,11 +754,9 @@ impl ParameterValue {
754754
}
755755

756756
/// Returns the raw string value of the parameter.
757-
#[allow(clippy::missing_const_for_fn)]
758-
pub fn value(&self) -> &str {
757+
pub const fn value(&self) -> &str {
759758
match self {
760-
ParameterValue::String(s) => s,
761-
ParameterValue::Typed { value, .. } => value,
759+
ParameterValue::String(value) | ParameterValue::Typed { value, .. } => value.as_str(),
762760
}
763761
}
764762

0 commit comments

Comments
 (0)