diff options
| author | tingerrr <me@tinger.dev> | 2024-02-04 12:23:29 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-02-04 11:23:29 +0000 |
| commit | a8f764ab484de735b3099870204fa613f4f2a2db (patch) | |
| tree | 2bcccbe878e6782d85414e57f3a4ee0a1d3a6a55 /crates/typst-cli/src/main.rs | |
| parent | 2594b367010028277240273e99ab32ac352461f3 (diff) | |
Fix error swallowing (#3338)
Diffstat (limited to 'crates/typst-cli/src/main.rs')
| -rw-r--r-- | crates/typst-cli/src/main.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/typst-cli/src/main.rs b/crates/typst-cli/src/main.rs index c7221f77..5e1ef47c 100644 --- a/crates/typst-cli/src/main.rs +++ b/crates/typst-cli/src/main.rs @@ -50,7 +50,7 @@ fn main() -> ExitCode { .leave_alternate_screen() .map_err(|err| eco_format!("failed to leave alternate screen ({err})")); - if let Err(msg) = res.or(res_leave) { + if let Some(msg) = res.err().or(res_leave.err()) { set_failed(); print_error(&msg).expect("failed to print error"); } |
