Skip to content

Commit

Permalink
status
Browse files Browse the repository at this point in the history
  • Loading branch information
DanielReid committed Mar 3, 2017
1 parent e452456 commit a6cd836
Showing 1 changed file with 10 additions and 7 deletions.
17 changes: 10 additions & 7 deletions standalone-app/pataviHandlers.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,11 @@ function getPataviTask(request, response) {
modelRepository.setTaskUrl(modelCache.id, createdUrl, callback);
},
function() {
response.sendStatus(httpStatus.CREATED);
response.json({
uri: createdUrlCache
});
response
.status(httpStatus.CREATED)
.json({
uri: createdUrlCache
});
}
],
function(error) {
Expand All @@ -65,9 +66,11 @@ function getMcdaPataviTask(request, response) {
response.sendStatus(httpStatus.INTERNAL_SERVER_ERROR);
response.end();
} else {
response.json({
uri: taskUrl
});
response
.status(httpStatus.CREATED)
.json({
uri: taskUrl
});
}
});
}

0 comments on commit a6cd836

Please sign in to comment.