Steps to reproduce:
1. Enable profile module.
2. Add URL field to profile fields.
3. Try to register user with "abc" value in URL fields.
Expected result:
Form error "abc is not valid URL".
Actual results:
No error, successful registration.
The bug is caused by wrong _profile_get_fields() call, which requires $register parameter to return all fields on registration. As it's not being passed during registration, no validators are being called.
The solution is to pass "$category == 'account'" value into $register parameter, as it TRUE only on registration (actually, for user/%/edit it's being called true, but as there's no fields there, it's not matters).
I'm not providing the D7 patch, as it seems, profiles system will (or already is) change completely in it.
| Comment | File | Size | Author |
|---|---|---|---|
| profile.module-fields-validation-in-registration.patch | 646 bytes | neochief |
Comments
Comment #1
neochief commentedAfter some testing, I found that his solution is wrong. Finding another...
Comment #2
dpearcefl commentedHas this been fixed in the latest D6?
Comment #3
dpearcefl commented