Skip to content

Commit

Permalink
Change Certificate::sign signing function parameter from Fn to FnOnce
Browse files Browse the repository at this point in the history
  • Loading branch information
obelisk committed Apr 3, 2021
1 parent 47521f7 commit 17453aa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/ssh/cert.rs
Original file line number Diff line number Diff line change
Expand Up @@ -407,7 +407,7 @@ impl Certificate {
}

/// Take the certificate settings and generate a valid signature using the provided signer function
pub fn sign(mut self, signer: impl Fn(&[u8]) -> Option<Vec<u8>>) -> Result<Self> {
pub fn sign(mut self, signer: impl FnOnce(&[u8]) -> Option<Vec<u8>>) -> Result<Self> {
let mut writer = super::Writer::new();
let kt_name = format!("{}[email protected]", self.key.key_type.name);
// Write the cert type
Expand Down

0 comments on commit 17453aa

Please sign in to comment.