mirror of
https://github.com/astro/buzzrelay.git
synced 2024-11-22 04:00:59 +00:00
delint
This commit is contained in:
parent
01f8cc2f5f
commit
f7f632a971
2 changed files with 2 additions and 2 deletions
|
@ -109,7 +109,7 @@ impl<'a> Endpoint<'a> {
|
||||||
private_key: &PrivateKey,
|
private_key: &PrivateKey,
|
||||||
) -> Result<Actor, Error> {
|
) -> Result<Actor, Error> {
|
||||||
let remote_actor: Actor = serde_json::from_value(
|
let remote_actor: Actor = serde_json::from_value(
|
||||||
authorized_fetch(&client, &self.remote_actor_uri, key_id, private_key).await?
|
authorized_fetch(client, &self.remote_actor_uri, key_id, private_key).await?
|
||||||
)?;
|
)?;
|
||||||
let public_key = PublicKey::from_pem(remote_actor.public_key.pem.as_bytes())?;
|
let public_key = PublicKey::from_pem(remote_actor.public_key.pem.as_bytes())?;
|
||||||
if ! (self.signature.verify(&public_key)?) {
|
if ! (self.signature.verify(&public_key)?) {
|
||||||
|
|
|
@ -34,6 +34,6 @@ where
|
||||||
if res.status() >= StatusCode::OK && res.status() < StatusCode::MULTIPLE_CHOICES {
|
if res.status() >= StatusCode::OK && res.status() < StatusCode::MULTIPLE_CHOICES {
|
||||||
Ok(res.json().await?)
|
Ok(res.json().await?)
|
||||||
} else {
|
} else {
|
||||||
Err(Error::Response(format!("{}", res.text().await?)))
|
Err(Error::Response(res.text().await?))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue