|
|
|
|
58
|
(defun write-document (document &optional theme-fn &rest render-args)
|
58
|
(defun write-document (document &optional theme-fn &rest render-args)
|
59
|
"Write the given DOCUMENT to disk as HTML. If THEME-FN is present,
|
59
|
"Write the given DOCUMENT to disk as HTML. If THEME-FN is present,
|
60
|
use it as the template passing any RENDER-ARGS."
|
60
|
use it as the template passing any RENDER-ARGS."
|
61
|
- (let ((html (if render-args
|
|
|
|
|
61
|
+ (let ((html (if (or theme-fn render-args)
|
62
|
(apply #'render-page document theme-fn render-args)
|
62
|
(apply #'render-page document theme-fn render-args)
|
63
|
(render-page document nil))))
|
63
|
(render-page document nil))))
|
64
|
(write-file (page-path obj) html)))
|
64
|
(write-file (page-path obj) html)))
|