mirror of
https://github.com/bitwarden/browser
synced 2025-12-16 08:13:42 +00:00
Improve desktop IPC logging (#11864)
* Improve desktop IPC logging * Log error * Force file to only log info, like the desktop app does * use ?
This commit is contained in:
2
apps/desktop/desktop_native/napi/index.d.ts
vendored
2
apps/desktop/desktop_native/napi/index.d.ts
vendored
@@ -109,6 +109,8 @@ export declare namespace ipc {
|
||||
* @param callback This function will be called whenever a message is received from a client.
|
||||
*/
|
||||
static listen(name: string, callback: (error: null | Error, message: IpcMessage) => void): Promise<IpcServer>
|
||||
/** Return the path to the IPC server. */
|
||||
getPath(): string
|
||||
/** Stop the IPC server. */
|
||||
stop(): void
|
||||
/**
|
||||
|
||||
@@ -487,6 +487,12 @@ pub mod ipc {
|
||||
Ok(IpcServer { server })
|
||||
}
|
||||
|
||||
/// Return the path to the IPC server.
|
||||
#[napi]
|
||||
pub fn get_path(&self) -> String {
|
||||
self.server.path.to_string_lossy().to_string()
|
||||
}
|
||||
|
||||
/// Stop the IPC server.
|
||||
#[napi]
|
||||
pub fn stop(&self) -> napi::Result<()> {
|
||||
|
||||
Reference in New Issue
Block a user