diff --git a/controllers/resources.js b/controllers/resources.js index 61becf46a5..aefafe02c0 100644 --- a/controllers/resources.js +++ b/controllers/resources.js @@ -192,6 +192,15 @@ module.exports = { allBonfireIds: function() { return bonfires.map(function(elem) { + return { + _id: elem._id, + difficulty: elem.difficulty + } + }) + .sort(function(a, b) { + return a.difficulty - b.difficulty; + }) + .map(function(elem) { return elem._id; }) }