Closed robertgarrigos closed 1 month ago
Line 763 of references_dialog.module:
'#element_validate' => array('_element_validate_integer_positive'),
provably should be:
'#element_validate' => array('references_element_validate_integer_positive'),
which means references should be added as dependency also.
Thanks for pointing me to that page. I'll make the proper changes.
Just updated the PR
This is not the right approach to fix this problem. You added a function that's available in another module (references) and then added a dependency, which creates problems for people like #33 who use this module with entityreference - this forces them to install a module they don't need.
A better approach is to replace the textfield
form element with a number
form element, which already includes an integer numerical validation, meaning you can get rid of the #element_validate
.
Can we please revisit this fix and fix the fix? ;-)
I'm talking about this fix, that was merged recently: https://github.com/backdrop-contrib/references_dialog/commit/ea13c9b6b8b636c5841402578424b724f69e5485
Although, sorry, I see that was reverted in the current release. However, the unnecessary dependency was not removed.
fixed
I've found this fatal error when saving a field after setting the "Add dialog" check