From 8b46cc19d847aa44886d8925467f8d8a2be8c770 Mon Sep 17 00:00:00 2001 From: Jonathan Bernard Date: Mon, 1 Oct 2018 11:22:31 -0400 Subject: [PATCH] Rename variable to avoid overloading the name. --- src/pit_api.nim | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pit_api.nim b/src/pit_api.nim index 643a5f0..58769c9 100644 --- a/src/pit_api.nim +++ b/src/pit_api.nim @@ -81,14 +81,14 @@ proc start*(cfg: PitApiCfg) = get "/issues": checkAuth(cfg); if not authed: return true - var (stripAnsi, args) = paramsToArgs(request.params) + var (hasColor, args) = paramsToArgs(request.params) args = @["list"] & args info "args: \n" & args.join(" ") let execResult = execWithOutput("pit", ".", args) if execResult[2] != 0: resp(Http500, stripAnsi($execResult[0] & "\n" & $execResult[1]), TXT) else: - if stripAnsi: resp(stripAnsi(execResult[0]), TXT) + if hasColor: resp(stripAnsi(execResult[0]), TXT) else: resp(execResult[0], TXT) post "/issues":