[PR #5633] fix: add team name validation and trimming (fixes #5543) #5294

Open
opened 2026-03-17 02:45:16 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/hoppscotch/hoppscotch/pull/5633
Author: @seoyiju
Created: 11/29/2025
Status: 🔄 Open

Base: mainHead: main


📝 Commits (2)

📊 Changes

2 files changed (+12 additions, -4 deletions)

View changed files

📝 packages/hoppscotch-common/src/components/teams/Add.vue (+7 -1)
📝 packages/hoppscotch-common/src/components/teams/Edit.vue (+5 -3)

📄 Description


Summary by cubic

Validate and trim team names in Add and Edit flows to prevent empty or whitespace-only names and leading/trailing spaces. Fixes #5543 with local checks before calling the API.

  • Bug Fixes
    • Trim input and validate with TeamNameCodec before API calls.
    • Block empty/whitespace names and show an error toast.
    • Guard against duplicate saves when loading.
    • Use trimmed name in Add.vue and Edit.vue (including renameTeam).

Written for commit ae4586e354. Summary will update automatically on new commits.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/hoppscotch/hoppscotch/pull/5633 **Author:** [@seoyiju](https://github.com/seoyiju) **Created:** 11/29/2025 **Status:** 🔄 Open **Base:** `main` ← **Head:** `main` --- ### 📝 Commits (2) - [`c9b16ec`](https://github.com/hoppscotch/hoppscotch/commit/c9b16ec3a0672e6f0ab9cd24a26184ce1c7e5301) Update Add.vue - [`ae4586e`](https://github.com/hoppscotch/hoppscotch/commit/ae4586e354ddbc836d77862f3b32526980bda901) Update Edit.vue ### 📊 Changes **2 files changed** (+12 additions, -4 deletions) <details> <summary>View changed files</summary> 📝 `packages/hoppscotch-common/src/components/teams/Add.vue` (+7 -1) 📝 `packages/hoppscotch-common/src/components/teams/Edit.vue` (+5 -3) </details> ### 📄 Description <!-- This PR fixes issue #5543 by validating and trimming team names in Add.vue and Edit.vue. - Prevents saving empty or whitespace-only team names - Prevents team names starting/ending with spaces - Added local validation before calling API <!-- This is an auto-generated description by cubic. --> --- ## Summary by cubic Validate and trim team names in Add and Edit flows to prevent empty or whitespace-only names and leading/trailing spaces. Fixes #5543 with local checks before calling the API. - **Bug Fixes** - Trim input and validate with TeamNameCodec before API calls. - Block empty/whitespace names and show an error toast. - Guard against duplicate saves when loading. - Use trimmed name in Add.vue and Edit.vue (including renameTeam). <sup>Written for commit ae4586e354ddbc836d77862f3b32526980bda901. Summary will update automatically on new commits.</sup> <!-- End of auto-generated description by cubic. --> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hoppscotch#5294
No description provided.