Skip to main content

notify_terminal

Function notify_terminal 

Source
pub async fn notify_terminal<E, C>(
    transfer: &Transfer,
    channel: &E,
    log: &NotificationLogHandle,
    os_notifier: &OsNotifier<C>,
) -> Result<(), AppError>
Expand description

Push an in-app notification for a terminal-state transfer, and optionally fire an OS notification based on the current settings.

§Parameters

  • transfer — The transfer that reached a terminal state.
  • channel — Event emitter used to broadcast notification:new.
  • log — In-app notification log (shared Tauri state).
  • os_notifier — OS notification bridge (settings-gated).

§Return

Returns Ok(()) on success. Errors from the in-app log broadcast are returned; OS notification errors are silently logged (non-fatal for the transfer outcome).