diff --git a/plugins/recruit-resources/src/components/EditVacancy.svelte b/plugins/recruit-resources/src/components/EditVacancy.svelte index 09d86a2bf0..c440156307 100644 --- a/plugins/recruit-resources/src/components/EditVacancy.svelte +++ b/plugins/recruit-resources/src/components/EditVacancy.svelte @@ -106,7 +106,7 @@ const updates: Partial> = {} const trimmedName = rawName.trim() - if (trimmedName.length > 0 && trimmedName !== object.name) { + if (trimmedName.length > 0 && trimmedName !== object.name?.trim()) { updates.name = trimmedName } diff --git a/plugins/tracker-resources/src/components/issues/edit/EditIssue.svelte b/plugins/tracker-resources/src/components/issues/edit/EditIssue.svelte index 22d3037a13..b093af3b17 100644 --- a/plugins/tracker-resources/src/components/issues/edit/EditIssue.svelte +++ b/plugins/tracker-resources/src/components/issues/edit/EditIssue.svelte @@ -108,7 +108,7 @@ const trimmedTitle = title.trim() - if (trimmedTitle.length > 0 && trimmedTitle !== issue.title) { + if (trimmedTitle.length > 0 && trimmedTitle !== issue.title?.trim()) { await client.update(issue, { title: trimmedTitle }) } } diff --git a/plugins/tracker-resources/src/components/templates/EditIssueTemplate.svelte b/plugins/tracker-resources/src/components/templates/EditIssueTemplate.svelte index cd7e6dbe14..e58e5c7c14 100644 --- a/plugins/tracker-resources/src/components/templates/EditIssueTemplate.svelte +++ b/plugins/tracker-resources/src/components/templates/EditIssueTemplate.svelte @@ -97,7 +97,7 @@ const trimmedTitle = title.trim() - if (trimmedTitle.length > 0 && trimmedTitle !== template.title) { + if (trimmedTitle.length > 0 && trimmedTitle !== template.title?.trim()) { await client.update(template, { title: trimmedTitle }) } }