The function og_block_visibility_set_visibility() in uses module_exist() instead of module_exists(). This causes the error Fatal error: Call to undefined function module_exist() in /var/www/html/intranet/includes/common.inc(1355) : eval()'d code on line 2 and the page won't show. The correct function call should be to module_exists().

I'm using Drupal 5.12 with OG Block Visibility 5.x-1.2.

/**
 * Set block visibility to be restricted to a given group
 *
 * @param $module
 *   The module to which the block belongs
 * @param $delta
 *   Which of the module's blocks
 * @param $nid
 *   Group node ID
 */
function og_block_visibility_set_visibility($module, $delta, $groups) {

  // Create PHP visibility string
  $php = "
if (module_exist('og_block_visibility')) {
  return og_block_visibility_check('$module', '$delta');
}
";

Comments

Anonymous’s picture

Assigned: Unassigned »

It looks as though i only made the change to the development branch. Would you please download 5.x-1.3

Thanks Paul

Anonymous’s picture

Status: Active » Fixed
eriktoyra’s picture

I have downloaded 5.x-1.3 and it now works fine. Thanks for the update!

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.