From 4bbf3dc2097f1de206fa053fac32f675d4ae2927 Mon Sep 17 00:00:00 2001 From: Benjamin Shirley-Quirk Date: Wed, 5 Aug 2020 02:14:46 +0100 Subject: factored out unnecessary NimVersions --- src/main.nim | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) (limited to 'src/main.nim') diff --git a/src/main.nim b/src/main.nim index 458ba72..d8ad5a5 100644 --- a/src/main.nim +++ b/src/main.nim @@ -11,16 +11,11 @@ import "feature/syncsource" proc execSudo*(args: seq[Argument]): int = - when NimVersion >= "1.2": - execResult(sudoPrefix & getAppFilename() & (block:collect(newSeq): - for y in args: - for x in y.collectArg: - x - )) - else: - execResult(sudoPrefix & getAppFilename() & - lc[x | (y <- args, x <- y.collectArg), string]) - + execResult(sudoPrefix & getAppFilename() & (block:collect(newSeq): + for y in args: + for x in y.collectArg: + x + )) proc passValidation(args: seq[Argument], config: Config, nonRootArgs: openArray[OptionPair], rootArgs: openArray[OptionPair], opts: varargs[seq[CommandOption]]): int = -- cgit v1.2.3-70-g09d2