mirror of
https://github.com/hexedtech/codemp.git
synced 2024-12-22 21:04:53 +01:00
fix(js): remove unneded result wraps
This commit is contained in:
parent
79f063123e
commit
4191fc2257
2 changed files with 5 additions and 6 deletions
|
@ -27,15 +27,14 @@ impl BufferController {
|
|||
}
|
||||
|
||||
#[napi(js_name = "clear_callback")]
|
||||
pub fn js_clear_callback(&self) -> napi::Result<()> {
|
||||
pub fn js_clear_callback(&self) -> () {
|
||||
self.clear_callback();
|
||||
Ok(())
|
||||
}
|
||||
|
||||
|
||||
#[napi(js_name = "get_path")]
|
||||
pub fn js_path(&self) -> napi::Result<&str> {
|
||||
Ok(self.path())
|
||||
pub fn js_path(&self) -> &str {
|
||||
self.path()
|
||||
}
|
||||
|
||||
#[napi(js_name = "poll")]
|
||||
|
|
|
@ -41,8 +41,8 @@ impl Client {
|
|||
|
||||
#[napi(js_name = "leave_workspace")]
|
||||
/// leave workspace and disconnect, returns true if workspace was active
|
||||
pub async fn js_leave_workspace(&self, workspace: String) -> napi::Result<bool> {
|
||||
Ok(self.leave_workspace(&workspace))
|
||||
pub async fn js_leave_workspace(&self, workspace: String) -> bool {
|
||||
self.leave_workspace(&workspace)
|
||||
}
|
||||
|
||||
#[napi(js_name = "get_workspace")]
|
||||
|
|
Loading…
Reference in a new issue