Having used Path Access and Role Weights together on a 5.x install I couldn't figure out why the same set up was not working on a 6.x install.

I took a look at path_access.module and found a D6 comment and code checking for role_weights commented out. I was able to get it working by uncommenting the line and commenting out the foreach ($user->roles) but my question is, why drop support for Role Weights?

CommentFileSizeAuthor
#3 path_access_role_weights_support.patch1.77 KBcirrus3d

Comments

mrfelton’s picture

Version: 6.x-1.0 » 7.x-1.x-dev
Status: Active » Patch (to be ported)

Committed to D6:
http://drupalcode.org/project/path_access.git/commitdiff/83ecdff?hp=32ec...

We need this for D7 once role_weights has been ported.

pfaocle’s picture

I've finally created a 7.x-1.x branch with code copied over from it's temporary home on GitHub. The branch should be available here soon.

Note that the function role_weights_get_highest() has been removed, so you'll need something like:

  $role = module_invoke('role_weights', 'get_weighted_max', $user->roles, 'lightest');
cirrus3d’s picture

Issue summary: View changes
StatusFileSize
new1.77 KB

Patch attached (against 7.x-1.0-beta2)