Hi all,

After installing the Storm module, i wanted to take a look at storm. I clicked on "storm" in the menu at the home-page, and i got the following error:

Fatal error: Call to undefined function stormorganization_access() in /var/www/drupal/sites/all/modules/storm/storm.module on line 644

Around line 644 in the specified file i can find the following method (I highlighted line 644):

function storm_icon_add($path, $item, $params=array()) {
  global $user;
  $type = $item->type;
  // D7 TODO - change to _node_access
  $af = $type .'_access';
  if (!$af('create', $item, $user)) return ''; // <--line 644
  $attributes = array('class' => 'popups-form');
  return storm_icon_l('application_add', $path, t('Add'), '', $params, $attributes);
}

If you need additional infos, please tell me.
Thanks,
Philipp

Comments

koenen’s picture

Noting a comment in the code: "// D7 TODO - change to _node_access" , I implemented a hack for now... got me past this error.

function storm_icon_add($path, $item, $params=array()) {
global $user;
$type = $item->type;
// D7 TODO - change to _node_access
$af = $type .'_access';
if ( $af.'x' == 'stormorganization_accessx' ) $af = 'stormorganization_node_access'; // << my temp. hack.
if (!$af('create', $item, $user)) return '';
$attributes = array('class' => 'popups-form');
return storm_icon_l('application_add', $path, t('Add'), '', $params, $attributes);
}

I don't mind assisting with the correct patch if I could get some direction on what the "TODO" is about.

juliangb’s picture

The problem is that I believe that the way that Storm has previously defined its node access rules will need to change in D7 due to the change in the database layer. The hack above may hide the error, but there needs to be more work to actually sort things properly.

Note, the D7 version is not yet ready for use, as stated on the release notes. I've demoted it from the project page to discourage use for now.

The best way of contributing towards the D7 release is actually to work on some of the issues that I have highlighted in #888924: Release of 6.x-1.35 for D6.

juliangb’s picture

Status: Active » Closed (works as designed)

D7 port not completed yet.