Commit ec0a45db718c35d8bc298567ca64c9f9e9d480f5
1 parent
11e0134c
Exists in
master
and in
3 other branches
Adjust routes response
Showing
2 changed files
with
3 additions
and
3 deletions
Show diff stats
translate-api/app.js
... | ... | @@ -47,9 +47,9 @@ app.use(function(req, res, next) { |
47 | 47 | /** |
48 | 48 | * Register routes. |
49 | 49 | */ |
50 | -app.use('/', bundle); | |
51 | -app.use('/translate', translate); | |
52 | 50 | app.use('/video', video); |
51 | +app.use('/translate', translate); | |
52 | +app.use('/', bundle); | |
53 | 53 | |
54 | 54 | /** |
55 | 55 | * Error handler. | ... | ... |
translate-api/controllers/bundle.js
... | ... | @@ -23,7 +23,7 @@ exports.index=function(req, res, next) { |
23 | 23 | amqp.receiveFromQueue(id, 'lists', false, res, function(err, message) { |
24 | 24 | if (err) |
25 | 25 | return error.internalError('An internal communication error has occurred.', next); |
26 | - res.status(200).json(JSON.parse(message)); | |
26 | + res.status(200).send(message); | |
27 | 27 | }); |
28 | 28 | }); |
29 | 29 | }; | ... | ... |