From edc13efd09ba19c55719a8ab58f0acc7f0af2a2f Mon Sep 17 00:00:00 2001 From: Bastian Eicher Date: Sun, 26 Nov 2023 21:12:31 +0100 Subject: [PATCH] Bootstrap: Simplified logic for offering --machine argument --- src/Bootstrap/BootstrapProcess.Args.cs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/Bootstrap/BootstrapProcess.Args.cs b/src/Bootstrap/BootstrapProcess.Args.cs index f1295f69c..8fea44a0a 100644 --- a/src/Bootstrap/BootstrapProcess.Args.cs +++ b/src/Bootstrap/BootstrapProcess.Args.cs @@ -158,12 +158,11 @@ public BootstrapProcess(IBootstrapHandler handler) }); _options.Add("wait", () => "Wait for {_embeddedConfig.AppName} to exit after running it.", _ => _wait = true); } - if (BootstrapConfig.Instance.IntegrateArgs is {} integrateArgs) + if (BootstrapConfig.Instance.IntegrateArgs != null) { _options.Add("no-integrate", () => $"Do not integrate {appName} into the desktop environment.", _ => _noIntegrate = true); _options.Add("integrate-args=", () => "Override command-line arguments for '0install integrate'.", x => _integrateArgs = x); - if (!integrateArgs.Contains("--machine")) - _options.Add("machine", () => $"Integrate {appName} machine-wide (for the entire computer) instead of just for the current user.", _ => _machineWide = true); + _options.Add("machine", () => $"Integrate {appName} machine-wide (for the entire computer) instead of just for the current user.", _ => _machineWide = true); } } else