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.
When using the function og_vocab_get_accessible_vocabs without passing any entity type or entity the function throws the next notices:
Notice: Undefined index: entity keys in entity_extract_ids() (line 7636 of /var/www/drupal/includes/common.inc).
Notice: Undefined index: entity keys in entity_extract_ids() (line 7637 of /var/www/drupal/includes/common.inc).
Because those arguments are not mandatory i reset the $bundle variable and if the arguments are passed to the function then we need to use the entity_extract_ids function.
Comment | File | Size | Author |
---|---|---|---|
#5 | 1864634-og-bundle-4.patch | 439 bytes | bricel |
#3 | 1864634-og-bundle-3.patch | 1.06 KB | RoySegall |
#2 | 1864634-og-bundle-2.patch | 802 bytes | amitaibu |
og_vocab_get_accessible_vocabs.patch | 528 bytes | RoySegall | |
Comments
Comment #1
RoySegall CreditAttribution: RoySegall commentedComment #2
amitaibuComment #3
RoySegall CreditAttribution: RoySegall commentedLet's just use the entity and the bundle as arguments.
Comment #4
amitaibuCommitted, thanks.
Comment #5
bricel CreditAttribution: bricel commentedFix previous patch function call with wrong parameter.
Comment #6
amitaibuCommitted, thanks.