Fatal error: Call to undefined method UserRestrictions::mask() in \sites\all\modules\user_restrictions\user_restrictions_ui.admin.inc on line 77

CommentFileSizeAuthor
#5 Capture.PNG13.49 KBnortont

Comments

erikvip’s picture

I've got the same error when trying to access 'admin/config/people/user-restrictions/add'

Anonymous’s picture

Title: Fatal error: Call to undefined method UserRestrictions::mask() » Call to undefined method UserRestrictions::mask()
Anonymous’s picture

Status: Active » Fixed

I removed all those methods that were accessing the object properties as those properties are now public.
I have committed the changed, and created a new official release.

Thank you for your report.

nortont’s picture

Status: Fixed » Active

I installed the new release as I was having the same issue as above.
That issue is fixed but now when adding a rule I get this

PDOException: SQLSTATE[HY093]: Invalid parameter number: number of bound variables does not match number of tokens: SELECT ur.urid AS urid FROM {user_restrictions} ur WHERE (type = :type AND LOWER(:mask) = LOWER(mask)) ; Array ( [status] => 0 [type] => [mask] => %@lawnlesson.com [submit] => Save rule [form_build_id] => form-80LQ3u9f-f6oGiyQdRmyldBjkeS4dHzy4ZehYmRg3M8 [form_token] => EgNLqBx_fB0kPIawJAUvQC84Go4_F7yb8YzupcnDAos [form_id] => user_restrictions_ui_edit_rule_form [op] => Save rule ) in UserRestrictions::exists() (line 114 of /home/nortroni/public_html/drupal/sites/all/modules/user_restrictions/user_restrictions.classes.inc)...

I also believe there is part of the UI missing per the attached screen shot

nortont’s picture

StatusFileSize
new13.49 KB
Anonymous’s picture

Status: Active » Fixed

@nortont: Thank you for your report. May you open a different report, as that is a different issue?

Status: Fixed » Closed (fixed)

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

  • Commit cdb37c0 on 7.x-1.x, 8.x-1.x by kiam:
    #1034650 by kiam: Call to undefined method UserRestrictions::mask(). By...