The following error occurs when viewing the recent changes RSS feed after upgrading Diff from 6.x-2.0 to 6.x-2.1:

Fatal error: Call to undefined function _diff_body_rows() in /home/pathtodrupalinstallation/sites/all/modules/recent_changes/recent_changes.module on line 592

I have used the Recent Changes module for years (which depends on the Diff module) with no issues. However upgrading to the new version of diff causes the viewing of the RSS feed to break.

The recent changes module isn't maintained very actively, so I'm raising the issue here in the hope someone can point me to what needs to be changed in the recent_changes.module file based on an understanding of what changed in the new version of Diff.

Summary:
What works:
Drupal 6.20
Diff 6.x-2.0
Recent Changes 6.x-1.x-dev (July 11, 2010)

What doesn't work
Drupal 6.20
Diff 6.x-2.1
Recent Changes 6.x-1.x-dev (July 11, 2010)

I have attached the .module files of the relevant versions.

Thanks in advance.

CommentFileSizeAuthor
relevent files.zip18.07 KBfuzzy_texan
Support from Acquia helps fund testing for Drupal Acquia logo

Comments

ledom’s picture

Solved by adding this into recent_changes.module

module_load_include('inc', 'diff', 'diff.pages');

Before:

function _recent_changes_get_diff($node, $prev_revision) {
  // Check for diff module
  if (!module_exists('diff')) {
    return '';
  }

  // Crete diff
  $rows = _diff_body_rows($prev_revision, $node);
  $cols = _diff_default_cols();
  $header = array();

After:

function _recent_changes_get_diff($node, $prev_revision) {
  // Check for diff module
  if (!module_exists('diff')) {
    return '';
  }

	module_load_include('inc', 'diff', 'diff.pages'); 

  // Crete diff
  $rows = _diff_body_rows($prev_revision, $node);
  $cols = _diff_default_cols();
  $header = array();
itserich’s picture

Thank you, #2 works.

Alan D.’s picture

Project: Diff » Recent Changes
Version: 6.x-2.1 » 6.x-1.x-dev

Wrong queue :)

Alan D.’s picture