Reviewed & tested by the community
Project:
Organic Groups Notifications
Version:
7.x-2.x-dev
Component:
Code
Priority:
Critical
Category:
Bug report
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
29 May 2014 at 20:11 UTC
Updated:
9 Nov 2018 at 16:56 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
edvanleeuwenI think the subscriptions are not retrieved properly in Notifications, so I am changing the project.
Comment #2
edvanleeuwenI think I have found the cause. In og_notifications.inc the function object_value() contains
If this just returns the array_pop($node_groups), everything seems to be fine. But obviously, the double pop is there for a reason. I am not sure how to solve this.
Comment #3
edvanleeuwenChanging the priority to Major.
Comment #4
edvanleeuwenChanged version.
Comment #5
edvanleeuwenTurned out to be caused by a patch. Following up there.
Comment #6
edvanleeuwenI am reopening this, as this occurs with the current dev version (without the patch in the related issue).
Comment #7
edvanleeuwenThis problem still persists. Effect is that no more than one og can be related to content, as only the last one is notified.
Comment #8
edvanleeuwenThe solution seems easy: in object_value replace
return array_pop($entity_group);with
return $entity_group;Patch attached.
Comment #9
edvanleeuwenWhat can I do to have this tested and reviewed?
Comment #10
indigoxela commentedI think this issue needs a different approach.
It is not correct to take only the last group, using "all" is even worse as the link text says "..in the current group".
There can be hundreds of organic groups on a site and many of them listed in og_group_ref in random order.
We need to get the current group, which requires og submodule og_context.
Patch is attached.
Comment #11
jacob.embree commentedI believe #8 is correct. It worked for me.
#10 does not fix the issues.
Comment #12
jacob.embree commentedComment #13
lokapujyaWe either need to add automated tests, or someone has to test it and show the results.