mirror of
https://github.com/hexedtech/codemp-vscode.git
synced 2024-12-23 05:54:51 +01:00
removed unneeded napi result
This commit is contained in:
parent
1cbfc49df1
commit
d0d37b1b71
2 changed files with 6 additions and 6 deletions
|
@ -79,8 +79,8 @@ impl JsBufferController {
|
|||
|
||||
|
||||
#[napi]
|
||||
pub fn content(&self) -> napi::Result<String> {
|
||||
Ok(self.0.content())
|
||||
pub fn content(&self) -> String {
|
||||
self.0.content()
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -33,13 +33,13 @@ impl JsCodempClient {
|
|||
|
||||
#[napi]
|
||||
/// get workspace with given id, if it exists
|
||||
pub async fn get_workspace(&self, workspace: String) -> napi::Result<Option<JsWorkspace>> {
|
||||
Ok(self.0.read().await.get_workspace(&workspace).map(|w| JsWorkspace::from(w)))
|
||||
pub async fn get_workspace(&self, workspace: String) -> Option<JsWorkspace> {
|
||||
self.0.read().await.get_workspace(&workspace).map(|w| JsWorkspace::from(w))
|
||||
}
|
||||
|
||||
#[napi]
|
||||
/// return current sessions's user id
|
||||
pub async fn user_id(&self) -> napi::Result<String> {
|
||||
Ok(self.0.read().await.user_id().to_string())
|
||||
pub async fn user_id(&self) -> String {
|
||||
self.0.read().await.user_id().to_string()
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue