Skip to content

Commit

Permalink
Fix translatable string
Browse files Browse the repository at this point in the history
  • Loading branch information
ismaelbej committed Sep 6, 2024
1 parent df21939 commit ceb36c0
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
7 changes: 4 additions & 3 deletions assets/js/components/collaborators/InviteModal.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ export class InviteModal extends Component {
</InputWithLabel>
{emailError ? (
<span className="small-text-bellow text-error">
{t(emailError)}
{emailError}
</span>
) : (
<span />
Expand Down Expand Up @@ -191,6 +191,7 @@ export class InviteModal extends Component {
}

getEmailError(guest) {
const { t } = this.props
let errorCode = "invalid-email"
if (guest.data.email) {
errorCode = guest.errors.email
Expand All @@ -200,10 +201,10 @@ export class InviteModal extends Component {
case null:
return null
case "existing-email":
return "User is already a member"
return t("User is already a member")
case "invalid-email":
default:
return "Please enter a valid email"
return t("Please enter a valid email")
}
}
}
Expand Down
1 change: 1 addition & 0 deletions locales/template/translation.json
Original file line number Diff line number Diff line change
Expand Up @@ -526,6 +526,7 @@
"Use SHIFT+ENTER to split in multiple parts": "",
"Use different expressions in order to standardize the source phone number.": "",
"User": "",
"User is already a member": "",
"Valid entries": "",
"Value \"{{value}}\" already used in a previous response": "",
"Value already used in a previous response": "",
Expand Down

0 comments on commit ceb36c0

Please sign in to comment.