summaryrefslogtreecommitdiff
path: root/cider-client.el
diff options
context:
space:
mode:
authorVitalie Spinu <spinuvit@gmail.com>2017-07-16 21:45:52 +0200
committerBozhidar Batsov <bozhidar.batsov@gmail.com>2017-07-19 22:12:26 +0300
commitddf3f358bca2e1c4840647f39dcdbf77860a38d7 (patch)
treece9255c6c352eb4e60d75ed8b4be907bfaa3da6d /cider-client.el
parent154dd39138cac4b65ad413037853b3aef530049f (diff)
Add connection argument to cider-nrepl-sync-request:eval
Diffstat (limited to 'cider-client.el')
-rw-r--r--cider-client.el13
1 files changed, 6 insertions, 7 deletions
diff --git a/cider-client.el b/cider-client.el
index 80c7be2c..0f1757a2 100644
--- a/cider-client.el
+++ b/cider-client.el
@@ -702,13 +702,12 @@ buffer, defaults to (cider-current-connection)."
ns line column additional-params)
(cider-spinner-start connection)))
-(defun cider-nrepl-sync-request:eval (input &optional ns)
- "Send the INPUT to the nREPL server synchronously.
-If NS is non-nil, include it in the request."
- (nrepl-sync-request:eval
- input
- (cider-current-connection)
- ns))
+(defun cider-nrepl-sync-request:eval (input &optional connection ns)
+ "Send the INPUT to the nREPL CONNECTION synchronously.
+If NS is non-nil, include it in the eval request."
+ (nrepl-sync-request:eval input
+ (or connection (cider-current-connection))
+ ns))
(defcustom cider-pprint-fn 'pprint
"Sets the function to use when pretty-printing evaluation results.