mongoose + tests

This commit is contained in:
Primakov Alexandr Alexandrovich
2024-10-16 11:06:23 +03:00
parent 2cfcd7347b
commit 4b0d9b4dbc
1295 changed files with 4579 additions and 1719 deletions
+2 -7
View File
@@ -1,4 +1,4 @@
const getAnswer = (errors, data, success = true) => {
exports.getAnswer = (errors, data, success = true) => {
if (errors) {
return {
success: false,
@@ -12,7 +12,7 @@ const getAnswer = (errors, data, success = true) => {
}
}
const getResponse = (errors, data, success = true) => {
exports.getResponse = (errors, data, success = true) => {
if (errors.length) {
return {
success: false,
@@ -28,8 +28,3 @@ const getResponse = (errors, data, success = true) => {
warnings: [],
}
}
module.exports = {
getAnswer,
getResponse,
}