fix: clippy lints

This commit is contained in:
Xiphoseer
2024-05-31 20:01:07 +02:00
parent 44fb9280c1
commit baee58829f
3 changed files with 3 additions and 20 deletions
+3 -4
View File
@@ -71,10 +71,9 @@ impl Borrow<str> for PercentDecoded {
}
}
impl ToString for PercentDecoded {
#[inline]
fn to_string(&self) -> String {
self.0.clone()
impl fmt::Display for PercentDecoded {
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
f.write_str(&self.0)
}
}
-3
View File
@@ -5,9 +5,6 @@ use serde::Serialize;
use super::ReverseLookup;
#[derive(Serialize)]
struct LootMatrixResult {}
#[derive(Debug, Default, Clone, Serialize)]
pub struct LootMatrixIndexRev {
#[serde(skip_serializing_if = "LootMatrixIndexComponents::is_empty")]
-13
View File
@@ -1,17 +1,4 @@
use latin1str::Latin1Str;
use serde::Serialize;
#[derive(Debug, Clone, PartialEq, Eq, Serialize)]
pub(crate) struct BehaviorTemplate<'a> {
#[serde(rename = "behaviorID")]
behavior_id: i32,
#[serde(rename = "templateID")]
template_id: i32,
#[serde(rename = "effectID")]
effect_id: i32,
#[serde(rename = "effectHandle")]
effect_handle: &'a Latin1Str,
}
pub fn match_action_key(key: &Latin1Str) -> bool {
matches!(