Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Getting this error on the Drupal db update page.
Notice: Undefined index: membership_type in og_entity_property_info() (line 236 of /home/.../public_html/profiles/commons/modules/contrib/og/og.module).
Comment | File | Size | Author |
---|---|---|---|
#5 | Schermafdruk_08-03-13_16_39-og-membership_type-error.jpg | 750.9 KB | silkogelman |
Comments
Comment #1
ezra-g CreditAttribution: ezra-g commentedDoes the error recur, or does it only happen when you run update.php?
Comment #2
bjprodneyl CreditAttribution: bjprodneyl commentedHi,
It only appears when I run update.
Comment #3
debain CreditAttribution: debain commentedSame problem, paste this code inside the foreach loop near line 236:
Run cron (and watch output). You should see an empty field...
Comment #4
silkogelman CreditAttribution: silkogelman commentedI ran into the same 'Notice: 'Undefined index: membership_type in og_entity_property_info() (line 236'
with Commerce Kickstart 2.4.
Localization on
Drupal 7.20
Organic Groups 2.0
Comment #5
silkogelman CreditAttribution: silkogelman commentedIn my case this happens when running update.php
and when editing a Drupal Commerce Product Display page.
The Product Display page references a Drupal Commerce product, and the product references an Organic Group.
Comment #6
WebSinPat CreditAttribution: WebSinPat commentedI am getting the same error, in a commons 3.2 install.
I see the error (same error printed about a dozen times) when i clear caches and run cron.
And every so often as i'm just navigating the site and doing a page load, I will get the error (just printed once or twice in this case). It does not repeat if i reload the same page.
thanks.
Comment #7
t.payne CreditAttribution: t.payne commentedbumping this
More or less a clean installation (though I have done a little tinkering with other parts of the installation, but not with anything OG)
Notice: Undefined index: membership_type in og_entity_property_info() (line 236 of /home/p21r7220/public_html/sites/all/modules/og/og.module).
A patch of temp fix would be awesome, since thats not looking promising... any ideas on what it is I am looking for when I start to debug would be great as I am 100% new to OG (but not drupal)
I have read all the comments in this thread (and though there are a few theories at to the problem there is nothing definitive)
edit: spelling
Comment #7.0
t.payne CreditAttribution: t.payne commentedRemoved uneccessary path info.
Comment #8
lsolesen CreditAttribution: lsolesen commentedClosing old inactive issues. Please reopen if the problem persists in recent 3.15 version of Commons.
Comment #10
rodriguesribeiro CreditAttribution: rodriguesribeiro commentedHello,
same here, any hint please?
Many thanks in advance
ER
Comment #11
Tankeroo CreditAttribution: Tankeroo commentedI'm getting the same error for line 236.
membership_type in og_entity_property_info() (line 236
No idea how to fix it. Also, not a lot of results come up when searching for a fix.
Comment #12
debain CreditAttribution: debain commentedHave you done what i have written in #3 ? What is the output?
Comment #13
Tankeroo CreditAttribution: Tankeroo commentedYes, I did. Thanks! Here's what I got.
This is the original freach
When I insert your code here:
I get the following.
When I insert the code near the beginning before $params, I get this:
If I enter your code after the whole $info[entity_type] array, I get the same results as the first where og_vocabulary is empty.
I don't know exactly how to debug this.
EDIT: Added more details.
Comment #14
debain CreditAttribution: debain commentedUnfortunately i can't remeber exactly how i solved this issue. I am sure it was a setting in the field or the content.
Now we are sure it has something to do with the og_vocabulary. Have a look at that field, something is missing there. Are there (old) nodes where the value (of that field) is not set? Set it or remove that nodes.
(The message is a notice, not an errror, maybe you could simply ignore it: write a function that checks if the value is empty... )
Comment #15
lsolesen CreditAttribution: lsolesen commentedComment #16
Tankeroo CreditAttribution: Tankeroo commentedI think it's fixed now. Thanks to your advice, I found the og_vocabulary field and just deleted it.
Used Taxonomy instead.
Kudos debain!
Comment #17
lsolesen CreditAttribution: lsolesen commented