diff options
author | Tom Willemsen | 2013-03-23 16:50:18 +0100 |
---|---|---|
committer | Tom Willemsen | 2013-03-23 16:50:18 +0100 |
commit | 977627a8af0e5028e95a679773a0c750987a17b7 (patch) | |
tree | 1a943ec260835ebfc02ced2bca2bc4a264a3a05d /lisp/clark.lisp | |
parent | fdce2ed81ca73cc67abffc88615da1ed58b3f502 (diff) | |
download | clark-977627a8af0e5028e95a679773a0c750987a17b7.tar.gz clark-977627a8af0e5028e95a679773a0c750987a17b7.zip |
Simplify the exists command
Diffstat (limited to 'lisp/clark.lisp')
-rw-r--r-- | lisp/clark.lisp | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/lisp/clark.lisp b/lisp/clark.lisp index e85c5c9..3c288c3 100644 --- a/lisp/clark.lisp +++ b/lisp/clark.lisp @@ -170,14 +170,9 @@ omitted or any number of tag names." Check if URL exists in the database. Prints `yes' when found and `no' otherwise." - (if (execute-single *db* "SELECT rowid FROM bookmark WHERE url = ?" - (car args)) - (progn - (format t "yes~%") - 0) - (progn - (format t "no~%") - 1))) + (format t "~:[no~;yes~]~%" + (execute-single + *db* "SELECT rowid FROM bookmark WHERE url = ?" (car args)))) (defcommand help "Show help message." |