When I had role name something like "User [with editation]" and tried to add some other role permission to edit or delete this role (edit users with role User [with editation]) system returned an error after submitting the form. After I changed the role name to standard brackets () it started working.

Probably something with function

function administerusersbyrole_perm() {
  $roles = db_query('SELECT name FROM {role} WHERE rid > 2 ORDER BY name');
  $perms = array();
  $perms[] = 'create users';
  while ($role=db_fetch_array($roles)) {
    $perms[] = 'edit users with role '. $role['name'];
    $perms[] = 'delete users with role '. $role['name'];
  }
  return $perms;
}

Character escaping would probably solve this. Didnt tested that though.

Comments

smokris’s picture

Version: 5.x-1.4 » 6.x-1.x-dev
Assigned: Unassigned » smokris
Status: Active » Fixed

I don't think there exists a way to escape characters for use in permissions strings.

I've added a workaround, which removes any non-alphanumeric characters from the permissions strings generated by Administer Users by Role.

Committed to 6.x-1.x-dev as http://drupalcode.org/project/administerusersbyrole.git/commit/44cd055.

Status: Fixed » Closed (fixed)

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