Skip to content

🐛Bug: Feedback Form Submits Empty String #1415

Open
@vishwajeet1729

Description

@vishwajeet1729

Describe the bug

The feedback form allows submission even when the comment field is empty. This results in blank feedback entries being recorded.

Steps To Reproduce

Leave the "feedback-comment" field empty.
Click the submit button.
The form submits successfully instead of showing an error

Expected Behavior

The form should prevent submission when the comment field is empty and display an error message instead.

Screenshots

Image

Device Information [optional]

- OS:
- Browser:
- version:

Are you working on this issue?

Yes

Do you think this work might require an [Architectural Decision Record (ADR)]? (significant or noteworthy)

No

Solution:

code to be added in the file website/components/DocsHelp.tsx

const feedbackComment = formData.get('feedback-comment')?.toString().trim();
if (!feedbackComment) {
setError('Feedback comment cannot be empty.');
return false;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    Status: AvailableNo one has claimed responsibility for resolving this issue.good first issueGood for newcomers🐛 BugIndicates that the issue is a bug or defect.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions