diff options
author | Andy Wingo | 2012-02-11 18:54:51 +0100 |
---|---|---|
committer | Andy Wingo | 2012-02-11 18:54:51 +0100 |
commit | afec0daa992123035f4bf63c5365b09f2df1e1af (patch) | |
tree | d2c73d2af22cfce84e8c795bdedf62a71daf49d8 /COPYING | |
parent | f89e4b128ba83415e045daf500303d24fbcb0083 (diff) | |
download | tekuti-afec0daa992123035f4bf63c5365b09f2df1e1af.tar.gz tekuti-afec0daa992123035f4bf63c5365b09f2df1e1af.zip |
stop hitting git when fetching post metadata
Inspired by a patch from Aleix Conchillo FlaquƩ. Thanks, Aleix!
* tekuti/index.scm (index-specs):
* tekuti/post.scm (reindex-posts, reindex-posts-by-date): Change to have
the "posts" index be a hash table mapping key -> post.
"posts-by-date" is a list of keys, from newest to oldest.
(post-from-git): This is what post-from-key was.
(post-from-key): New function, pulls out a post from the posts hash
table.
(munge-post): Use post-from-git.
(delete-post): Take the post directly.
(latest-posts): New awesome helper for fetching the lastest N posts
that match some predicates.
* tekuti/page-helpers.scm (find-posts-matching): Adapt to post-from-key
change.
(published-posts): Remove, replaced with latest-posts.
* tekuti/page.scm (page-admin, page-admin-posts, page-admin-post)
(page-archives, page-feed-atom): Use the new latest-posts helper.
(page-admin-delete-post, page-admin-delete-comment, page-show-post)
(page-new-comment, page-show-tag): Adapt to post-from-key change.
* tekuti/tags.scm (compute-related-posts, compute-related-tags): Adapt
to post-from-key change.
(reindex-tags): Use latest-posts.
Diffstat (limited to 'COPYING')
0 files changed, 0 insertions, 0 deletions