Add tests for getMonitorById
This commit is contained in:
1 parent
3e23d97930
commit
586b18d295
2 files changed
+63
-3
No files matched your search
@@ -130,9 +130,10 @@ const getMonitorById = async (req, res, next) => {
|
||||
if (!monitor) {
|
||||
const error = new Error(errorMessages.MONITOR_GET_BY_ID);
|
||||
error.status = 404;
|
||||
throw error;
|
||||
}
|
||||
|
||||
return res.json({
|
||||
return res.status(200).json({
|
||||
success: true,
|
||||
msg: successMessages.MONITOR_GET_BY_ID,
|
||||
data: monitor,
|
||||
|
||||
Reference in new issue
Block a user