Hi Jacob,

thx for your drupal adminrole module. I just test it on a drupal 6 site.
it works well, except a little annoyance:
I have this message in every page of my site:
warning: Invalid argument supplied for foreach() in /xxxx/htdocs/xxxxxx/includes/menu.inc on line 258.

After investigation, it seems that something is incorrect in the adminrole_menu function ... i don't know what exactly ... sorry ..... somewhere here :

  $items['admin/adminrole/update'] = array(
    'title' => t('Update AdminRole'),
    'page callback' => 'adminrole_update_perms',
    'access arguments' => user_access('administer site configuration'),
    'type' => MENU_CALLBACK
  );

Because there is a "bad" entry in the mysql table "menu_router" for the row
path = admin/adminrole/update
The column
access_arguments = b:1;

and when the line 257 of menu.inc try to unserialise this ... it's not a "good" unserialised array... and the next line (foreach) .... throw an error.

I Hope this can help !

For you info, i'm on a drupal 6.2 .... will try with 6.3 as soon as I can.

Comments

JacobSingh’s picture

Hi NIco,

this was fixed just a couple hours after my blog post went out (community review rocks) :)

Try the latest version.

Best,
J

JacobSingh’s picture

Status: Active » Closed (duplicate)
nico059’s picture

Thx Jacob, it works No 1 ;-)