File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -9,7 +9,6 @@ use devtools_wire_format::sources::sources_server::SourcesServer;
99use devtools_wire_format:: tauri:: tauri_server;
1010use devtools_wire_format:: tauri:: tauri_server:: TauriServer ;
1111use futures:: { FutureExt , TryStreamExt } ;
12- use http:: HeaderValue ;
1312use std:: net:: SocketAddr ;
1413use tokio:: sync:: mpsc;
1514use tonic:: codegen:: http:: Method ;
@@ -55,13 +54,8 @@ impl Server {
5554 let cors = CorsLayer :: new ( )
5655 // allow `GET` and `POST` when accessing the resource
5756 . allow_methods ( [ Method :: GET , Method :: POST ] )
58- . allow_headers ( AllowHeaders :: any ( ) ) ;
59-
60- let cors = if option_env ! ( "__DEVTOOLS_LOCAL_DEVELOPMENT" ) . is_some ( ) {
61- cors. allow_origin ( tower_http:: cors:: Any )
62- } else {
63- cors. allow_origin ( HeaderValue :: from_str ( "https://devtools.crabnebula.dev" ) . unwrap ( ) )
64- } ;
57+ . allow_headers ( AllowHeaders :: any ( ) )
58+ . allow_origin ( tower_http:: cors:: Any ) ;
6559
6660 let router = tonic:: transport:: Server :: builder ( )
6761 . accept_http1 ( true )
You can’t perform that action at this time.
0 commit comments