Display just the latest tumblr photo post instead of all posts
This commit is contained in:
@ -90,7 +90,7 @@ exports.getTumblr = function(req, res) {
|
||||
res.render('api/tumblr', {
|
||||
title: 'Tumblr API',
|
||||
blog: data.blog,
|
||||
photos: _.flatten(_.pluck(data.posts, 'photos')),
|
||||
photoset: data.posts[0].photos,
|
||||
user: req.user
|
||||
});
|
||||
});
|
||||
|
@ -17,11 +17,11 @@ block content
|
||||
| API Endpoints
|
||||
|
||||
h3.text-primary #{blog.name}'s blog
|
||||
strong Blog Stats
|
||||
h4 Blog Stats
|
||||
p
|
||||
.btn.btn-xs.btn-primary-outline
|
||||
i.fa.fa-file-text-o
|
||||
| #{blog.posts} posts
|
||||
|
||||
for photo in photos
|
||||
img(src='#{photo.alt_sizes.slice(-3)[0].url}')
|
||||
h4 Latest Photo Post
|
||||
for photo in photoset
|
||||
img.item(src='#{photo.original_size.url}')
|
Reference in New Issue
Block a user