Comparing version 0.9.3 to 0.9.4
@@ -471,2 +471,27 @@ var fs = require("fs"), | ||
reed.all = function(callback) { | ||
reed.list(function(err, titles) { | ||
//create the series to load all posts asyncly in order. | ||
var getAllPosts = []; | ||
titles.forEach(function(title) { | ||
getAllPosts.push(function(cb) { | ||
reed.get(title, function(err, metadata, htmlContent) { | ||
var post = { | ||
title: title, | ||
metadata: metadata, | ||
htmlContent: htmlContent | ||
}; | ||
cb(err, post); | ||
}); | ||
}); | ||
}); | ||
//get all the posts. | ||
async.series(getAllPosts, function(err, posts) { | ||
callback(null, posts); | ||
}); | ||
}); | ||
} | ||
reed.refresh = function refresh() { | ||
@@ -473,0 +498,0 @@ if (!readyCheck(refresh, arguments)) return; |
@@ -7,3 +7,3 @@ { | ||
"tags": [ "redis", "blog" ], | ||
"version": "0.9.3", | ||
"version": "0.9.4", | ||
"homepage": "http://www.agnos.is/", | ||
@@ -10,0 +10,0 @@ "repository": { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
24469
578