From 5a16537d72931db14ca9f7a67c7b8def7d3f51bb Mon Sep 17 00:00:00 2001 From: Colin Okay Date: Tue, 23 Aug 2022 20:16:42 -0500 Subject: [add] new generated api client code; updated client.lisp --- lib/state.lisp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'lib/state.lisp') diff --git a/lib/state.lisp b/lib/state.lisp index e690f37..1f9f36b 100644 --- a/lib/state.lisp +++ b/lib/state.lisp @@ -160,6 +160,9 @@ user for some input if it does not." (read-config-file) (make-fresh-config))) +;;; HOSTS + +(defvar *host* nil) ;;; STATE LOADING MACRO @@ -169,18 +172,18 @@ sets the api's *host* variable. If BODY produces no errors, the " `(let* ((*config* (ensure-config)) (*cache* (read-cache-file)) (*drafts* (read-drafts-file)) - (api:*host* (config-host *config*)) + (*host* (config-host *config*)) (errorsp nil)) (unwind-protect (handler-case (progn - (assert api:*host* () "ol must be configured with a server host.") + (assert *host* () "ol must be configured with a server host.") (set-term-width) ,@body) (dexador.error:http-request-failed (e) (setf errorsp t) (format *error-output* "Operation failed. The server at ~a returned with ~a~%" - api:*host* + *host* (dexador.error:response-status e))) (error (e) (setf errorsp t) -- cgit v1.2.3