diff options
author | Colin Okay <cbeok@protonmail.com> | 2020-04-13 16:41:19 -0500 |
---|---|---|
committer | Colin Okay <cbeok@protonmail.com> | 2020-04-13 16:41:19 -0500 |
commit | 321b078ca5be33d2add66611c73e57c2e9b98d8b (patch) | |
tree | 7df97fba3f854509b3ffdff340474aa8aa2e09c0 /posterbot.lisp | |
parent | f470bb96dfb91d5020534ec78783c8ef30166582 (diff) |
nicer error printing
Diffstat (limited to 'posterbot.lisp')
-rw-r--r-- | posterbot.lisp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/posterbot.lisp b/posterbot.lisp index 2d2c652..c354154 100644 --- a/posterbot.lisp +++ b/posterbot.lisp @@ -81,7 +81,9 @@ the downloaded file. If there is an error thrown at any point, returns NIL." (file-stream (drakma:http-request link :want-stream t))) (loop :for bytes = (read-sequence buffer file-stream) :while (plusp bytes) :do (write-sequence buffer out)))) - (error () nil))) + (error (c) (progn + (format *error-output* "While downloading image file at ~a.~%Encountered Error: ~a~%~%" link c) + nil)))) (defun filename-from-link (link) |