Skip to content

Commit

Permalink
add daniel to readme, fix route
Browse files Browse the repository at this point in the history
  • Loading branch information
thegoleffect committed Aug 19, 2015
1 parent 38d0371 commit 11129f7
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
[Hapi-Plugins.com](https://hapi-plugins.com) is a searchable database of [Hapi.js](http://hapijs.com/) plugins. It was made for the book [Developing a hapi Edge](http://shop.oreilly.com/product/9781939902207.do) by:

- [Van Nguyen](https://twitter.com/thegoleffect)
- Daniel Bretoi
- [Daniel Bretoi](https://twitter.com/Eydaimon)
- [Wyatt Preul](https://twitter.com/wpreul)
- [Lloyd Benson](https://twitter.com/LloydWith2Ls)

Expand Down
12 changes: 8 additions & 4 deletions lib/routes.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,6 @@ exports.register = function (plugin, options, next) {
{ method: 'GET', path: '/plugins/{name}', config: Controllers.Plugin.get },
{ method: 'GET', path: '/plugins', config: Controllers.Plugin.search },

{ method: 'GET', path: '/admin/plugins/populate', config: Controllers.Plugin.populate },
{ method: 'GET', path: '/admin/plugins/populate/file', config: Controllers.Plugin.populate },
{ method: 'GET', path: '/admin/plugins/populate/source', config: Controllers.Plugin.populateReal },

{ method: 'GET', path: '/v1/downloads/{name}', config: Controllers.Plugin.getDownloadCounts },
{ method: 'GET', path: '/v1/downloads', config: Controllers.Plugin.getHottestPlugins },

Expand All @@ -41,6 +37,14 @@ exports.register = function (plugin, options, next) {
{ method: 'GET', path: '/heartbeat', config: Controllers.Static.heartbeat }
]);

if (!process.env.PRODUCTION) {
plugin.route([
{ method: 'GET', path: '/admin/plugins/populate', config: Controllers.Plugin.populate },
{ method: 'GET', path: '/admin/plugins/populate/file', config: Controllers.Plugin.populate },
{ method: 'GET', path: '/admin/plugins/populate/source', config: Controllers.Plugin.populateReal },
]);
}

plugin.views({
engines: {
html: {
Expand Down

0 comments on commit 11129f7

Please sign in to comment.