File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ ---
2+ " opener " : patch
3+ " opener-js " : patch
4+ ---
5+
6+ Fix broken JS commands ` opener.openPath ` and ` opener.openUrl ` on mobile.
Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ use tauri::{
99 AppHandle , Runtime ,
1010} ;
1111
12- use crate :: { scope:: Scope , Error } ;
12+ use crate :: { scope:: Scope , Error , OpenerExt } ;
1313
1414#[ tauri:: command]
1515pub async fn open_url < R : Runtime > (
@@ -34,7 +34,7 @@ pub async fn open_url<R: Runtime>(
3434 ) ;
3535
3636 if scope. is_url_allowed ( & url, with. as_deref ( ) ) {
37- crate :: open_url ( url, with)
37+ app . opener ( ) . open_url ( url, with)
3838 } else {
3939 Err ( Error :: ForbiddenUrl { url, with } )
4040 }
@@ -63,7 +63,7 @@ pub async fn open_path<R: Runtime>(
6363 ) ;
6464
6565 if scope. is_path_allowed ( Path :: new ( & path) , with. as_deref ( ) ) ? {
66- crate :: open_path ( path, with)
66+ app . opener ( ) . open_path ( path, with)
6767 } else {
6868 Err ( Error :: ForbiddenPath { path, with } )
6969 }
You can’t perform that action at this time.
0 commit comments