Your correct your solution Anthony works.

Massimo, I am not sure I understand what db.auth_user.username.
requires.insert(0, MyStrangeRequirement()) is doing?


On Thu, Mar 29, 2012 at 7:28 PM, Anthony <[email protected]> wrote:

> If i am correct this will not work because it should be:
>>
>> 1. check last character
>> 2. remove last character
>> 3. do db validation
>>
>> I think onvalidation does db validation and then 1&2.
>> Db validation will not pass because usernames are stored without last
>> character (as stated in first post).
>>
>
> The form validation just checks the username field validator, which is
> temporarily changed to IS_NOT_EMPTY, so it is only checking that a username
> was submitted. In any case, even the regular username field validator
> wouldn't check that the submitted value matches what's in the database. The
> check for matching the submitted username with an existing db username
> happens after the form processing, so using onvalidation should work.
>
> Anthony
>



-- 
-- 
Regards,
Bruce Wade
http://ca.linkedin.com/in/brucelwade
http://www.wadecybertech.com
http://www.warplydesigned.com
http://www.fitnessfriendsfinder.com

Reply via email to