-
-
Notifications
You must be signed in to change notification settings - Fork 597
Closed
Labels
Description
Bug Description
If you use ?? instead of or inside a form:create tag, the errors are incorrect.
It might not have anything to do with the form:create tag at all, but that's just where we noticed it.
Ref #3669
How to Reproduce
- Create a form named
contact - Add a required field to the blueprint, just so there's an easy way to cause a validation error.
- Use this template to output the form:
{{ form:create in="{foo ?? 'contact'}" }} {{ errors | dump }} {{ errors | ul }} <button>submit</button> {{ /form:create }} - See that
errorsis aViewErrorBag, and that it's not output as a list. - Change
??toor - See that
errorsis an array, and they're output correctly.
Environment
Statamic version: 3.1.22