Skip to content

Commit

Permalink
run prettify
Browse files Browse the repository at this point in the history
  • Loading branch information
CarlosQ96 committed Jun 28, 2023
1 parent 18e42e7 commit 6ca67f9
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/resolvers/projectResolver.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1336,7 +1336,10 @@ export class ProjectResolver {
i18n.__(translationErrorMessagesKeys.AUTHENTICATION_REQUIRED),
);

if (content?.replace(/<[^>]+>/g, '').length > PROJECT_UPDATE_CONTENT_MAX_LENGTH) {
if (
content?.replace(/<[^>]+>/g, '')?.length >
PROJECT_UPDATE_CONTENT_MAX_LENGTH
) {
throw new Error(
i18n.__(
translationErrorMessagesKeys.PROJECT_UPDATE_CONTENT_LENGTH_SIZE_EXCEEDED,
Expand Down Expand Up @@ -1398,7 +1401,10 @@ export class ProjectResolver {
i18n.__(translationErrorMessagesKeys.AUTHENTICATION_REQUIRED),
);

if (content?.replace(/<[^>]+>/g, '').length > PROJECT_UPDATE_CONTENT_MAX_LENGTH) {
if (
content?.replace(/<[^>]+>/g, '')?.length >
PROJECT_UPDATE_CONTENT_MAX_LENGTH
) {
throw new Error(
i18n.__(
translationErrorMessagesKeys.PROJECT_UPDATE_CONTENT_LENGTH_SIZE_EXCEEDED,
Expand Down

0 comments on commit 6ca67f9

Please sign in to comment.