The hook sms_user_user_validate() does not appear to fire. If I register as a new user with an existing number in the sms_user table in the database, the uid relating to that number/row is changed to that of my new user.

Thanks,

David

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

smassally’s picture

I think sms_user_user_validate() depends on hook_user_validate which is not in d7 core. You'ld have to implement in a validate function if you hook into the form using hook_form_alter

ekes’s picture

Title: sms_user_user_validate() does not fire » No phone number validation on user registration form
Priority: Normal » Major

As mentioned by tarzan08201 sms_user save relies on the removed hook_user_validate() to check that the number is not a duplicate.

This is an issue for when the SMS number is shown on the registration form. Other case: Registration by SMS only happens if the number is not recognized; and Phone tab on user profile do validate the number first.

ekes’s picture

Status: Active » Needs review
FileSize
3.83 KB

Patch moves validation for both user edit, and user registration to #element_validation.

almaudoh’s picture

Issue summary: View changes
FileSize
6.14 KB

Re-rolled patch.

  • almaudoh committed 5906460 on 7.x-1.x
    Issue #1915022 by almaudoh, ekes | DaveyM: Fixed No phone number...
almaudoh’s picture

Status: Needs review » Fixed

Committed / pushed to 7.x-1.x

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.