fix(core): clear env args on restart test
// SPDX-License-Identifier: Apache-2.0
// SPDX-License-Identifier: MIT
+use tauri::Env;
+
fn main() {
let mut argv = std::env::args();
let argc = argv.len();
@@ -17,7 +19,11 @@ fn main() {
);
match argv.nth(1).as_deref() {
- Some("restart") => tauri::api::process::restart(&Default::default()),
+ Some("restart") => {
+ let mut env = Env::default();
+ env.args.clear();
+ tauri::api::process::restart(&env)
+ }
Some(invalid) => panic!("only argument `restart` is allowed, {} is invalid", invalid),
None => {}
};
