u
This commit is contained in:
@@ -26,6 +26,7 @@ function articlePropertyErrorStatus(error) {
|
||||
if (error.message === 'Not authorized') return 403;
|
||||
if (error.message === 'Company not found' || error.message === 'Article not found') return 404;
|
||||
if (error.message?.startsWith('Property not found')) return 404;
|
||||
if (error.message?.startsWith('Exclusive property cannot be overwritten')) return 409;
|
||||
if (error.message === 'Invalid properties array' || error.message === 'Invalid propertyId' || error.message === 'Duplicate propertyId') return 400;
|
||||
return 500;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user