This module works nicely but there are consistent warnings when creating some node types within a group.
Note: page is the only node associated with the og vocabulary
Page, forum, and image are fine. Project, poll, event, task, and blog are fine when created without a group selected but return the following warnings when created within a group.
* warning: array_keys() [function.array-keys]: The first argument should be an array in /web/gpo/gpo0/modules/og_vocab/og_vocab.module on line 111.
* warning: Invalid argument supplied for foreach() in /web/gpo/gpo0/modules/og_vocab/og_vocab.module on line 112.
This is on Drupal 4.7.2 and CiviCRM 1.4, upgraded from CS 0.8.3 (MySQL 5 and php 5.1) with the og modules from cvs
The new og features are great!
Neil
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | og_vocab_module.patch | 931 bytes | hintbw |
| #2 | og_vocab.module_patched | 6.73 KB | hintbw |
Comments
Comment #1
jo1ene commentedI get this arror as well ONLY when creating polls. I have poll, story, forum, event associated with groups. Other types are omitted. All content MUST be in groups. Drupal and OG 4.7 ehen I disable OG vocab. The error goes away.
Comment #2
hintbw commentedThe likely reason you are only getting the error when you create polls is that polls are the only group content type that you haven't assigned a vocabulary to (at least that is my experience). I found that any content type I wanted to create in a group setting that didn't have an og vocabulary assigned to would toss up the array errors. It appears to be incorrectly checking to see if any vocabularies even exist. I have attached a patched module (check line 111 to see the additional array check I added to eliminate the errors) because I'm not familiar with create patches yet (but I'll work on rolling a patch for it soon).
This patched module has solved this issue for me with og vocab.
Comment #3
hintbw commentedI have created my first true patch file for the og vocab module (the other one isn't really a patch file).
Comment #4
marcp commentedjust wondering if this conflicts at all with http://drupal.org/node/70470 or if these should be rolled into one patch...
Comment #5
hintbw commentedBased on what I can tell the two patches shouldn't conflict with one another. It appears that the free tagging info is still returned as an array and OG Vocab was throwing an error when returning node types that had no vocab attached. My patch just wraps the whole section with an array check - so the two patches should be able to be applied/committed without conflict. I'm going to try the free tagging patch and verify it to make sure.
Comment #6
rubenk commentedBump. Ineed this pretty badly
Comment #7
rubenk commentedInstalled patch for a different issue
http://drupal.org/node/70461
This seemed to also take care of posting error messages, or maybe its just my situation...not sure.
Comment #8
moshe weitzman commentedgood problem isolation. i fixed this in a slightly different way by checking if $form[taxonomy) is set. same idea.
Comment #9
(not verified) commented