remove validation at least 1 solution
This commit is contained in:
@@ -119,17 +119,6 @@ class ErrorCodeService {
|
|||||||
try {
|
try {
|
||||||
if (!data || typeof data !== "object") data = {};
|
if (!data || typeof data !== "object") data = {};
|
||||||
|
|
||||||
if (
|
|
||||||
!data.solution ||
|
|
||||||
!Array.isArray(data.solution) ||
|
|
||||||
data.solution.length === 0
|
|
||||||
) {
|
|
||||||
throw new ErrorHandler(
|
|
||||||
400,
|
|
||||||
"Error code must have at least 1 solution"
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
const errorId = await createErrorCodeDb(brandId, {
|
const errorId = await createErrorCodeDb(brandId, {
|
||||||
error_code: data.error_code,
|
error_code: data.error_code,
|
||||||
error_code_name: data.error_code_name,
|
error_code_name: data.error_code_name,
|
||||||
|
|||||||
Reference in New Issue
Block a user