mirror of
https://github.com/hexedtech/codemp.git
synced 2024-11-22 07:14:50 +01:00
fix(js): wrong argument, also remove Result<>
This commit is contained in:
parent
95f800c762
commit
297762c0b4
1 changed files with 5 additions and 5 deletions
|
@ -2,11 +2,11 @@ use napi_derive::napi;
|
||||||
|
|
||||||
|
|
||||||
#[napi(js_name = "hash")]
|
#[napi(js_name = "hash")]
|
||||||
pub fn js_hash(str : String) -> napi::Result<i64>{
|
pub fn js_hash(data: String) -> i64 {
|
||||||
Ok(crate::ext::hash(str))
|
crate::ext::hash(data)
|
||||||
}
|
}
|
||||||
|
|
||||||
#[napi(js_name = "version")]
|
#[napi(js_name = "version")]
|
||||||
pub fn js_version(str : String) -> napi::Result<String>{
|
pub fn js_version() -> String {
|
||||||
Ok(crate::version())
|
crate::version()
|
||||||
}
|
}
|
Loading…
Reference in a new issue