Minor code cleanup
Rob Mensching committed
Feb 25, 2022 at 22:24 UTC
aa201d92d19cca21bd2456e006a9eb51acafa0e9
1 file changed
+9
-3
src/wix/WixToolset.Core/CommandLine/CommandLineArguments.cs
+9
-3
@@ -41,7 +41,10 @@ namespace WixToolset.Core.CommandLine
41
this.ProcessArgumentsAndParseExtensions(this.OriginalArguments);
42
}
43
44
- public ICommandLineParser Parse() => new CommandLineParser(this.Messaging, this.Arguments, this.ErrorArgument);
44
+ public ICommandLineParser Parse()
45
+ {
46
+ return new CommandLineParser(this.Messaging, this.Arguments, this.ErrorArgument);
47
+ }
48
49
private void FlattenArgumentsWithResponseFilesIntoOriginalArguments(string[] commandLineArguments)
50
{
@@ -49,7 +52,7 @@ namespace WixToolset.Core.CommandLine
52
53
foreach (var arg in commandLineArguments)
54
{
52
- if (arg != null)
55
+ if (!String.IsNullOrEmpty(arg))
56
{
57
if ('@' == arg[0])
58
{
@@ -202,6 +205,9 @@ namespace WixToolset.Core.CommandLine
205
return arguments;
206
}
207
205
- private static bool IsSwitchAt(string[] args, int index) => args.Length > index && !String.IsNullOrEmpty(args[index]) && ('/' == args[index][0] || '-' == args[index][0]);
208
+ private static bool IsSwitchAt(string[] args, int index)
209
+ {
210
+ return args.Length > index && !String.IsNullOrEmpty(args[index]) && ('/' == args[index][0] || '-' == args[index][0]);
211
+ }
212
}
213
}