Skip to content

Commit b4fb115

Browse files
committed
fix: app crash error report dialog not coming in mac
1 parent fa30e81 commit b4fb115

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

src-tauri/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ dialog = "0.3.0"
4141
objc = "0.2.7"
4242
tauri-plugin-deep-link = "0.1.2"
4343
lazy_static = "1.4"
44-
dialog = "0.3.0"
44+
native-dialog = "0.7.0"
4545

4646
[features]
4747
# by default Tauri runs in production mode

src-tauri/src/main.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@ extern crate objc;
2727

2828
use clipboard_files;
2929

30-
#[cfg(any(target_os = "macos", target_os = "linux"))]
30+
#[cfg(target_os = "linux")]
3131
use dialog::DialogBox;
3232

33-
#[cfg(target_os = "windows")]
33+
#[cfg(any(target_os = "macos", target_os = "windows"))]
3434
use native_dialog::{MessageDialog, MessageType};
3535

3636
use regex::Regex;
@@ -285,7 +285,7 @@ fn main() {
285285
);
286286

287287
let mut should_log_to_bugsnag = false;
288-
#[cfg(any(target_os = "macos", target_os = "linux"))]
288+
#[cfg(target_os = "linux")]
289289
{
290290
let choice = dialog::Question::new(&error_message)
291291
.title("Oops! Phoenix Code Crashed :(")
@@ -296,7 +296,7 @@ fn main() {
296296
}
297297
}
298298

299-
#[cfg(target_os = "windows")]
299+
#[cfg(any(target_os = "macos", target_os = "windows"))]
300300
{
301301
should_log_to_bugsnag = MessageDialog::new()
302302
.set_type(MessageType::Error)

0 commit comments

Comments
 (0)