Skip to content

Commit 66f03fc

Browse files
committed
fix clippy
1 parent 199a03a commit 66f03fc

File tree

4 files changed

+8
-7
lines changed

4 files changed

+8
-7
lines changed

rust/catalyst-signed-doc-spec/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "catalyst-signed-doc-spec"
3-
version = "0.1.4"
3+
version = "0.1.5"
44
edition.workspace = true
55
authors.workspace = true
66
homepage.workspace = true

rust/signed_doc/src/providers.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,7 @@ pub mod tests {
105105
}
106106

107107
/// Returns a reference to the corresponding `SigningKey`.
108+
#[must_use]
108109
pub fn get_sk(
109110
&self,
110111
kid: &CatalystId,

rust/signed_doc/src/validator/rules/mod.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -126,17 +126,17 @@ impl Rules {
126126
ver: VerRule,
127127
content_type: ContentTypeRule::new(&doc_spec.headers.content_type)?,
128128
content_encoding: ContentEncodingRule::new(&doc_spec.headers.content_encoding)?,
129-
template: TemplateRule::new(&all_docs_specs, &doc_spec.metadata.template)?,
130-
parameters: ParametersRule::new(&all_docs_specs, &doc_spec.metadata.parameters)?,
129+
template: TemplateRule::new(all_docs_specs, &doc_spec.metadata.template)?,
130+
parameters: ParametersRule::new(all_docs_specs, &doc_spec.metadata.parameters)?,
131131
chain: ChainRule::new(&doc_spec.metadata.chain),
132-
doc_ref: RefRule::new(&all_docs_specs, &doc_spec.metadata.doc_ref)?,
133-
reply: ReplyRule::new(&all_docs_specs, &doc_spec.metadata.reply)?,
132+
doc_ref: RefRule::new(all_docs_specs, &doc_spec.metadata.doc_ref)?,
133+
reply: ReplyRule::new(all_docs_specs, &doc_spec.metadata.reply)?,
134134
section: SectionRule::NotSpecified,
135135
collaborators: CollaboratorsRule::new(&doc_spec.metadata.collaborators),
136136
content: ContentRule::new(&doc_spec.payload)?,
137137
kid: SignatureKidRule::new(&doc_spec.signers.roles)?,
138138
signature: SignatureRule,
139-
ownership: DocumentOwnershipRule::new(&doc_spec.signers.update, &doc_spec)?,
139+
ownership: DocumentOwnershipRule::new(&doc_spec.signers.update, doc_spec)?,
140140
})
141141
}
142142

rust/signed_doc/src/validator/rules/ownership/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ impl DocumentOwnershipRule {
119119
doc.report().missing_field("ref", REPORT_CONTEXT);
120120
return Ok(false);
121121
};
122-
let &[ref doc_ref] = doc_ref.as_slice() else {
122+
let [doc_ref] = doc_ref.as_slice() else {
123123
doc.report()
124124
.other("'ref' field cannot have multiple values", REPORT_CONTEXT);
125125
return Ok(false);

0 commit comments

Comments
 (0)