From 5dc5eb41dfddd266c914a205fc08c3148d79bf9b Mon Sep 17 00:00:00 2001 From: psychobunny Date: Tue, 11 Mar 2014 18:33:19 -0400 Subject: [PATCH] fixed ajaxify bug introduced in last commit --- src/routes/api.js | 2 -- src/routes/index.js | 1 + 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/routes/api.js b/src/routes/api.js index 6a79159416..8e35612179 100644 --- a/src/routes/api.js +++ b/src/routes/api.js @@ -102,8 +102,6 @@ function getRecentPosts(req, res, next) { module.exports = function(app, middleware, controllers) { app.namespace('/api', function () { - app.all('*', middleware.updateLastOnlineTime, middleware.prepareAPI); - app.get('/config', controllers.api.getConfig); app.get('/user/uid/:uid', middleware.checkGlobalPrivacySettings, controllers.accounts.getUserByUID); diff --git a/src/routes/index.js b/src/routes/index.js index e0ad25cb37..4a9503b593 100644 --- a/src/routes/index.js +++ b/src/routes/index.js @@ -122,6 +122,7 @@ module.exports = function(app, middleware) { adminRoutes(app, middleware, controllers); plugins.ready(function() { + app.all('/api/*', middleware.updateLastOnlineTime, middleware.prepareAPI); plugins.fireHook('action:app.load', app, middleware, controllers); metaRoutes(app, middleware, controllers);