File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -184,15 +184,17 @@ function makeExpressHandler(appId, promiseHandler) {
184184 res . status ( status ) ;
185185
186186 if ( result . text ) {
187- return res . send ( result . text ) ;
187+ res . send ( result . text ) ;
188+ return next ( ) ;
188189 }
189190
190191 if ( result . location ) {
191192 res . set ( 'Location' , result . location ) ;
192193 // Override the default expressjs response
193194 // as it double encodes %encoded chars in URL
194195 if ( ! result . response ) {
195- return res . send ( 'Found. Redirecting to ' + result . location ) ;
196+ res . send ( 'Found. Redirecting to ' + result . location ) ;
197+ return next ( ) ;
196198 }
197199 }
198200 if ( result . headers ) {
@@ -201,6 +203,7 @@ function makeExpressHandler(appId, promiseHandler) {
201203 } )
202204 }
203205 res . json ( result . response ) ;
206+ next ( ) ;
204207 } , ( e ) => {
205208 log . error ( `Error generating response. ${ inspect ( e ) } ` , { error : e } ) ;
206209 next ( e ) ;
You can’t perform that action at this time.
0 commit comments