I get the following warning, but all seems ok if I select the parent group manually while creating a subgroup.

warning: array_values() [function.array-values]: The argument should be an array in C:\sites\drupal66\sites\all\modules\og_subgroups\og_subgroups.module on line 273.

CommentFileSizeAuthor
#9 og_subgroups.module.patch796 bytesseutje

Comments

attiks’s picture

If I don't select a parent book, the node got created, but doesn't get attached to the parent.

amitaibu’s picture

Status: Active » Postponed (maintainer needs more info)

I didn't understand the scenario - can you attach a screenshot of your settings.

attiks’s picture

I have a link 'create subgroup' like this node/add/og_user_roles_subgroup?gids[]=231 which redirects to node/ognodeadd?type=project&gids[]=231

On that page I can select the book to which this node will belong:
- if I select the parent group I get the error message but the outline is good
- if I don't select the parent group I get a node which doesn't belong to a group and I have to use the 'outline' link to fix it.

I hope it's a clear now

amitaibu’s picture

By the link I think you use og_role. Please disable it and try again. Again, a screenshot will make it more clear,as I'm unable to reproduce.

attiks’s picture

You're 100% right, I'll check their issue queue

seutje’s picture

I just got the same error after disabling the access right for "administer book outlines"

before I disabled that I wasn't getting the error and I'm not getting the error on UID1

however, when I get the error, nothing went wrong... the outline is correct and everything

considering this happens in the propagate helper function, I suppose it might be usefull to share my propagate settings:

group post propagation: none

user propagation:

direction: parent
admins propagation: Don't propagate admin rights, only membership

Rights demotion: none

hope this helps

Leeteq’s picture

Subscribing.

seutje’s picture

might of fixed the issue by replacing lines 273 & 274:

$mlid = array_values($node_links[$gid]);
$mlid = $mlid[0]['mlid'];

with

$mlid = $node->book['mlid'];

but am yet to fully test if this leads to desired behavior

seutje’s picture

Status: Needs review » Postponed (maintainer needs more info)
StatusFileSize
new796 bytes

tiny patch for HEAD

it gets the mlid in a more reliable way I suppose

seutje’s picture

Status: Postponed (maintainer needs more info) » Needs review

forgot to change status

YK85’s picture

Version: 6.x-0.x-dev » 6.x-1.x-dev
Status: Postponed (maintainer needs more info) » Needs review

Hello,

Is this still an issue?

Thank you

bschilt’s picture

Version: 6.x-1.x-dev » 6.x-0.x-dev
Status: Needs review » Closed (won't fix)

This issue is only specific to the 6.x-0.x branch and that branch is no longer supported. The 6.x-1.x branch does not use the book module to create the hierarchies.