mirror of
https://github.com/formbricks/formbricks.git
synced 2026-04-24 11:39:22 -05:00
fix: skip button label validation for required nps and rating questions (#5153)
This commit is contained in:
committed by
GitHub
parent
2867c95494
commit
6671d877ad
@@ -146,6 +146,10 @@ export const validationRules = {
|
||||
fieldsToValidate = fieldsToValidate.filter((field) => field !== "backButtonLabel");
|
||||
}
|
||||
|
||||
if ((question.type === "nps" || question.type === "rating") && question.required) {
|
||||
fieldsToValidate = fieldsToValidate.filter((field) => field !== "buttonLabel");
|
||||
}
|
||||
|
||||
for (const field of fieldsToValidate) {
|
||||
if (
|
||||
question[field] &&
|
||||
|
||||
Reference in New Issue
Block a user