refact: remote printer, log (#11271)

Signed-off-by: fufesou <linlong1266@gmail.com>
This commit is contained in:
fufesou
2025-03-28 10:56:19 +08:00
committed by GitHub
parent ee2478168c
commit 4b14f86134
2 changed files with 12 additions and 11 deletions

View File

@@ -1569,11 +1569,14 @@ impl<T: InvokeUiSession> Remote<T> {
// Spawn a new thread to handle the print job.
// Or print job will block the ui thread.
std::thread::spawn(move || {
crate::platform::send_raw_data_to_printer(
printer_name,
data,
)
.ok();
if let Err(e) =
crate::platform::send_raw_data_to_printer(
printer_name,
data,
)
{
log::error!("Print job error: {}", e);
}
});
}
}