I have created a simple node type with cck and when I want to add a note at node/add/nodtype, I get the following error:

warning: Missing argument 2 for node_access() in C:\Programme\xampp\htdocs\modules\node\node.module on line 1965.

The node_access function does not get the argument "node". I do not know where this error occurs as I never call node_access within my modules. What is going wrong? Is there are way to find out what function has called the node_access function without the sencond argument (node)? Is there are debugging module? I have installed devel but this does not seem to have this functionality.

Thanks
Thomas

Comments

hansi99’s picture

warning: Missing argument 2 for node_access() in /var/www/vhosts/localtown.ca/httpdocs/cms/modules/node/node.module on line 1965.

what are the odds of only 2 people getting this error and no-one replies??

nandosk’s picture

I'm also getting exactly the same error whenever I try to edit posts, blog pages or articles.
It'd be nice if some could look into it.
It seems to be happening after I installed the advertisement module but not quite sure.

Missing argument 2 for node_access() in /home/.../public_html/.../modules/node/node.module on line 1965.

Even though my site is up and running live, it doesn't have any affect on its content or the final result. It's just annoying to be getting this message whenever I check the Recent log entries generated.

Hope one of you guys will be nice enough and come up with a way to solve it.
thanks

sjdavis’s picture

I too get this warning message when editing any content type:

warning: Missing argument 2 for node_access() in /vol/test/cms/cms2/modules/node/node.module on line 1965. I've tried everything I can think of to resolve this error. I've disabled recently enabled modules, cleared cache, cleared Views cache and Theme registry. I've also rebuilt content permissions and ran update.php. I'm currently running Drupal 6.10.

Any help would be much appreciated!

iaminawe’s picture

warning: Missing argument 2 for node_access() in vendor/acquia/modules/node/node.module on line 1993

pindaman’s picture

warning: Missing argument 2 for node_access() \node.module on line 1993

summit’s picture

Subscribing, having the same error on updating a module from drupal 5 to drupal 6, what could be the course please?

I think it has to do with this D6 function:

function business_access($op, $node, $account = NULL) {

    if ($op == 'create' && user_access('create businesses', $account)) {
        return TRUE;
    }

    if ($op == 'update' || $op == 'delete') {
        if (user_access('edit own businesses', $account) && ($account->uid == $node->uid)) {
            return TRUE;
        }
    }
}

Greetings, Martijn

summit’s picture

Anyone please?
greetings, Martijn

broncomania’s picture

same here...