fix(dashboard): accept Slack allow-all wildcard in allowed-users validation

The new SLACK_ALLOWED_USERS validation rejected '*', but the Slack gateway
honors '*' as an allow-all wildcard (gateway/platforms/slack.py DM auth,
slash-confirm, and approval-button paths). Accept '*' as a valid list entry
in both the API validator and the dashboard form so a value the runtime
honors is no longer blocked at setup.
This commit is contained in:
kshitijk4poor 2026-06-19 12:18:15 +05:30
parent d9190491a6
commit 83c034bd5b
3 changed files with 17 additions and 2 deletions

View file

@ -76,7 +76,7 @@ function validateMessagingEnvField(field: MessagingPlatformEnvVar, value: string
if (parts.some((part) => !part)) {
return "Slack member IDs must be comma-separated without empty entries.";
}
const invalid = parts.find((part) => !SLACK_MEMBER_ID_RE.test(part));
const invalid = parts.find((part) => part !== "*" && !SLACK_MEMBER_ID_RE.test(part));
if (invalid) {
return `${invalid} does not look like a Slack member ID. Use IDs like U01ABC2DEF3.`;
}