Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Drop -unencoded slot entirely when nil

  • Loading branch information...
commit 25d6bd9976ef3305243a5cb43547805d9e8099f7 1 parent 275f79f
Chas Emerick cemerick authored
Showing with 3 additions and 1 deletion.
  1. +3 −1 src/main/clojure/clojure/tools/nrepl/transport.clj
4 src/main/clojure/clojure/tools/nrepl/transport.clj
View
@@ -74,7 +74,9 @@
#(let [payload (be/read-bencode in)
unencoded (<bytes (payload "-unencoded"))
to-decode (apply dissoc payload "-unencoded" unencoded)]
- (merge payload {"-unencoded" unencoded} (<bytes to-decode)))
+ (merge (dissoc payload "-unencoded")
+ (when unencoded {"-unencoded" unencoded})
+ (<bytes to-decode)))
#(locking out
(doto out
(be/write-bencode %)
Please sign in to comment.
Something went wrong with that request. Please try again.