Skip to content

Commit 17d9182

Browse files
committed
Fix typo
1 parent 7966f16 commit 17d9182

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

linera-web/src/signer.rs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ pub enum JsSignerError {
2020
PublicKeyParseError = 2,
2121
JsConversionError = 3,
2222
UnexpectedSignatureFormat = 4,
23-
UknownError = 9,
23+
UnknownError = 9,
2424
}
2525

2626
impl Display for JsSignerError {
@@ -33,7 +33,7 @@ impl Display for JsSignerError {
3333
JsSignerError::UnexpectedSignatureFormat => {
3434
write!(f, "Unexpected signature format received from JS")
3535
}
36-
JsSignerError::UknownError => write!(f, "An unknown error occurred"),
36+
JsSignerError::UnknownError => write!(f, "An unknown error occurred"),
3737
}
3838
}
3939
}
@@ -47,10 +47,10 @@ impl From<JsValue> for JsSignerError {
4747
2 => JsSignerError::PublicKeyParseError,
4848
3 => JsSignerError::JsConversionError,
4949
4 => JsSignerError::UnexpectedSignatureFormat,
50-
_ => JsSignerError::UknownError,
50+
_ => JsSignerError::UnknownError,
5151
}
5252
} else {
53-
JsSignerError::UknownError
53+
JsSignerError::UnknownError
5454
}
5555
}
5656
}
@@ -104,6 +104,7 @@ impl Signer for JsSigner {
104104
.map_err(JsSignerError::from)?
105105
.as_string()
106106
.ok_or(JsSignerError::JsConversionError)?;
107+
web_sys::console::log_1(&JsValue::from_str(&js_public_key));
107108
let pk = EvmPublicKey::from_str(&js_public_key)
108109
.map_err(|_| JsSignerError::PublicKeyParseError)?;
109110
Ok(AccountPublicKey::EvmSecp256k1(pk))

0 commit comments

Comments
 (0)