Skip to content

Commit

Permalink
Merge branch 'task/OV-404-add-templates-logic' into task/OV-439-gener…
Browse files Browse the repository at this point in the history
…ate-preview-for-template
  • Loading branch information
sergiy4 committed Sep 26, 2024
2 parents 5a76b84 + 9bd6ded commit 2b03b47
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
const templateErrorMessage = {
YOU_CAN_NOT_DELETE_THIS_TEMPLATE: 'You can not delete this template',
YOU_CAN_NOT_UPDATE_THIS_TEMPLATE: 'You can not update this template',
TEMPLATE_DOES_NOT_EXIST: 'Template does not exist',
} as const;

Expand Down
2 changes: 1 addition & 1 deletion backend/src/bundles/templates/templates.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ class TemplateService implements Service {

if (template?.userId !== userId) {
throw new HttpError({
message: templateErrorMessage.YOU_CAN_NOT_DELETE_THIS_TEMPLATE,
message: templateErrorMessage.YOU_CAN_NOT_UPDATE_THIS_TEMPLATE,
status: HTTPCode.BAD_REQUEST,
});
}
Expand Down

0 comments on commit 2b03b47

Please sign in to comment.