From 292dad130dd62f30e50afaefbff792202262823d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Garc=C3=ADa=20Aubert?= Date: Wed, 7 Mar 2018 14:42:21 +0100 Subject: [PATCH] Move middlewares to the right place --- lib/cartodb/controllers/layergroup.js | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/lib/cartodb/controllers/layergroup.js b/lib/cartodb/controllers/layergroup.js index 6a50862f..1a853bd9 100644 --- a/lib/cartodb/controllers/layergroup.js +++ b/lib/cartodb/controllers/layergroup.js @@ -52,14 +52,14 @@ LayergroupController.prototype.register = function(app) { this.prepareContext, this.getMapStoreMapConfigProvider(this.mapStore, this.userLimitsApi), this.tile(this.tileBackend), - this.incrementSuccessMetrics(global.statsClient), - this.incrementErrorMetrics(global.statsClient), this.setCacheControlHeader(), this.setLastModifiedHeader(), this.getAffectedTables(this.layergroupAffectedTables, this.pgConnection), this.setCacheChannelHeader(), this.setSurrogateKeyHeader(this.surrogateKeysCache), + this.incrementSuccessMetrics(global.statsClient), this.sendResponse(), + this.incrementErrorMetrics(global.statsClient), this.tileError(), vectorError() ); @@ -71,14 +71,14 @@ LayergroupController.prototype.register = function(app) { this.prepareContext, this.getMapStoreMapConfigProvider(this.mapStore, this.userLimitsApi), this.tile(this.tileBackend), - this.incrementSuccessMetrics(global.statsClient), - this.incrementErrorMetrics(global.statsClient), this.setCacheControlHeader(), this.setLastModifiedHeader(), this.getAffectedTables(this.layergroupAffectedTables, this.pgConnection), this.setCacheChannelHeader(), this.setSurrogateKeyHeader(this.surrogateKeysCache), + this.incrementSuccessMetrics(global.statsClient), this.sendResponse(), + this.incrementErrorMetrics(global.statsClient), this.tileError(), vectorError() ); @@ -91,14 +91,14 @@ LayergroupController.prototype.register = function(app) { this.prepareContext, this.getMapStoreMapConfigProvider(this.mapStore, this.userLimitsApi), this.layer(this.tileBackend), - this.incrementSuccessMetrics(global.statsClient), - this.incrementErrorMetrics(global.statsClient), this.setCacheControlHeader(), this.setLastModifiedHeader(), this.getAffectedTables(this.layergroupAffectedTables, this.pgConnection), this.setCacheChannelHeader(), this.setSurrogateKeyHeader(this.surrogateKeysCache), + this.incrementSuccessMetrics(global.statsClient), this.sendResponse(), + this.incrementErrorMetrics(global.statsClient), this.tileError(), vectorError() );