update org url errors

This commit is contained in:
sua yoo 2024-07-16 12:59:12 -07:00
parent 8577b5bd93
commit 79ff806352
No known key found for this signature in database
GPG Key ID: 5AD1B4C02D4F0567
3 changed files with 12 additions and 6 deletions

View File

@ -397,10 +397,12 @@ export class Home extends LiteElement {
if (e.details === "duplicate_org_name") { if (e.details === "duplicate_org_name") {
message = msg("This org name is already taken, try another one."); message = msg("This org name is already taken, try another one.");
} else if (e.details === "duplicate_org_slug") { } else if (e.details === "duplicate_org_slug") {
message = msg("This org URL is already taken, try another one."); message = msg(
"This org URL identifier is already taken, try another one.",
);
} else if (e.details === "invalid_slug") { } else if (e.details === "invalid_slug") {
message = msg( message = msg(
"This org URL is invalid. Please use alphanumeric characters and dashes (-) only.", "This org URL identifier is invalid. Please use alphanumeric characters and dashes (-) only.",
); );
} }
} }

View File

@ -165,13 +165,15 @@ export class OrgForm extends TailwindElement {
} else if (e.details === "duplicate_org_slug") { } else if (e.details === "duplicate_org_slug") {
fieldName = "orgSlug"; fieldName = "orgSlug";
error = new Error( error = new Error(
msg(str`The org URL "${slug}" is already taken, try another one.`), msg(
str`The org URL identifier "${slug}" is already taken, try another one.`,
),
); );
} else if (e.details === "invalid_slug") { } else if (e.details === "invalid_slug") {
fieldName = "orgSlug"; fieldName = "orgSlug";
error = new Error( error = new Error(
msg( msg(
str`The org URL "${slug}" is not a valid URL. Please use alphanumeric characters and dashes (-) only`, str`The org URL identifier "${slug}" is not a valid URL. Please use alphanumeric characters and dashes (-) only`,
), ),
); );
} }

View File

@ -628,10 +628,12 @@ export class OrgSettings extends TailwindElement {
if (e.details === "duplicate_org_name") { if (e.details === "duplicate_org_name") {
message = msg("This org name is already taken, try another one."); message = msg("This org name is already taken, try another one.");
} else if (e.details === "duplicate_org_slug") { } else if (e.details === "duplicate_org_slug") {
message = msg("This org URL is already taken, try another one."); message = msg(
"This org URL identifier is already taken, try another one.",
);
} else if (e.details === "invalid_slug") { } else if (e.details === "invalid_slug") {
message = msg( message = msg(
"This org URL is invalid. Please use alphanumeric characters and dashes (-) only.", "This org URL identifier is invalid. Please use alphanumeric characters and dashes (-) only.",
); );
} }
} }