parent
8e92e1097e
commit
b4ec8adf9c
|
@ -4,7 +4,7 @@ RUN apk update && apk add bash
|
|||
|
||||
EXPOSE 5000
|
||||
RUN adduser -D -g '' r
|
||||
RUN chmod a+x /root/.nimble/bin/nimble
|
||||
RUN chmod a+x /opt/Nim/bin/nim
|
||||
|
||||
ADD . /app
|
||||
|
||||
|
|
|
@ -56,7 +56,7 @@ proc `%`(why: string): JsonNode =
|
|||
|
||||
template httpReply(code, body: expr): expr =
|
||||
## 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.
|
||||
resp code, myHeaders, pretty(%body, 4)
|
||||
else:
|
||||
|
|
Loading…
Reference in New Issue