Fix for Nim 0.12

Revert "fix"

This reverts commit f4bf5ebe0b.
This commit is contained in:
Christine Dodrill 2016-01-16 07:44:49 -08:00
parent 8e92e1097e
commit b4ec8adf9c
2 changed files with 2 additions and 2 deletions

View File

@ -4,7 +4,7 @@ RUN apk update && apk add bash
EXPOSE 5000 EXPOSE 5000
RUN adduser -D -g '' r RUN adduser -D -g '' r
RUN chmod a+x /root/.nimble/bin/nimble RUN chmod a+x /opt/Nim/bin/nim
ADD . /app ADD . /app

View File

@ -56,7 +56,7 @@ proc `%`(why: string): JsonNode =
template httpReply(code, body: expr): expr = template httpReply(code, body: expr): expr =
## Make things a lot simpler for replies, etc. ## Make things a lot simpler for replies, etc.
if request.headers["X-API-Options"] == "bare" or @"options" == "bare": if request.headers.getOrDefault("X-API-Options") == "bare" or @"options" == "bare":
# New "bare" reply format, easier to scrape, etc. # New "bare" reply format, easier to scrape, etc.
resp code, myHeaders, pretty(%body, 4) resp code, myHeaders, pretty(%body, 4)
else: else: