Merge pull request #77 from SVMBrown/master

conditionally drop any posts with dates set in the future
This commit is contained in:
Carmen La 2016-12-18 14:24:20 -05:00 committed by GitHub
commit fb0dc9e1d4

View file

@ -142,7 +142,8 @@
(remove #(= (:draft? %) true)))) (remove #(= (:draft? %) true))))
(m/markups)) (m/markups))
(sort-by :date) (sort-by :date)
reverse)) reverse
(drop-while #(and (:hide-future-posts? config) (.after (:date %) (:today config))))))
(defn read-pages (defn read-pages
"Returns a sequence of maps representing the data from markdown files of pages. "Returns a sequence of maps representing the data from markdown files of pages.