There are two errors in the _authcache_node_history() function:

  1. There is no check that the passed $nid parameter is valid before passing it to functions which assume its validity.
  2. The node_tag_new() function is called with a $nid parameter instead of a $node parameter.


pillarsdotnet’s picture

Status: Active » Needs review
971 bytes

Attached patch fixes both problems.

SocialNicheGuru’s picture

i get this error sometimes and the page goes white.

PHP Parse error: syntax error, unexpected '=', expecting ')' in /authcache/ajax/authcache.php on line 138

simg’s picture

@ SocialNicheGuru: do you have any reason to think your error is related to this particular issue ?

SocialNicheGuru’s picture

yep. the line of code was introduced by this patch

if (empty($node = node_load($nid))) {

I just did:
$node = node_load($nid);
if((empty($node) || ($node === NULL))

simg’s picture

Status: Needs review » Closed (fixed)

thanks guys, this issue now fixed in dev and 7.x-1.0