aboutsummaryrefslogtreecommitdiff
path: root/lib/client.lisp
diff options
context:
space:
mode:
authorColin Okay <okay@toyful.space>2022-03-13 14:45:28 -0500
committerColin Okay <okay@toyful.space>2022-03-13 14:45:28 -0500
commit7a97e9d6ba5737f1088dd3a81b9b16121cf47c39 (patch)
tree33f2ec9bad49ca2ca260ce1751604ae4457bce61 /lib/client.lisp
parent6890b0349f79c0fbbbe5b8b7b3dbf8c2d2262e79 (diff)
only print drafts when *drafts* is non null
Diffstat (limited to 'lib/client.lisp')
-rw-r--r--lib/client.lisp7
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/client.lisp b/lib/client.lisp
index dea6de6..aa7e896 100644
--- a/lib/client.lisp
+++ b/lib/client.lisp
@@ -79,9 +79,10 @@ running the body. If such a oneliner can be found."
(princ (oneliner-explanation ol)))))
(defun print-drafts ()
- (format t (concatenate 'string "~%~" (prin1-to-string *term-width*) "< ~;DRAFTS~; ~>~%"))
- (dolist (draft *drafts*)
- (print-oneliner-result-for-user (cdr draft))))
+ (when *drafts*
+ (format t (concatenate 'string "~%~" (prin1-to-string *term-width*) "< ~;DRAFTS~; ~>~%"))
+ (dolist (draft *drafts*)
+ (print-oneliner-result-for-user (cdr draft)))))
;;; RUNNING ONELINERS