When you "View Changes" when creating a new revision it throws this error:
Notice: Undefined index: #builder_function in diff_node_form_build_preview_changes() (line 204 of /ld/www/htdocs/sys/sops/sites/all/modules/diff/diff.module).

and the preview shows the old version of the node.

Comments

hansfn’s picture

StatusFileSize
new419 bytes

A change in the API - patch attached.

bryancasler’s picture

Just applied this patch, seems to work so far.

motravo’s picture

StatusFileSize
new673 bytes

hansfn, your patch did fix the "undefined index" error for me, but it introduced another problem: the first time I click "View Changes", it reports "No visible changes" and doesn't show any diffs. Clicking "View Changes" a second time successfully shows the diff. It apparently doesn't see the changes the first time because node_form_submit_build_node() has the side effect of modifying the node that will be returned by node_load(). I was able to fix it by calling node_load() first and making a copy of the result before calling node_form_submit_build_node(). My change is attached. I'm a PHP/Drupal noob, so somebody else should review this.

bryancasler’s picture

Status: Active » Reviewed & tested by the community

Had the same problems as the OP, patch from #3 works for me.

hswong3i’s picture

+1, also confirm #3 works for me ;-)

hswong3i’s picture

Priority: Normal » Critical
StatusFileSize
new878 bytes

I found that this critical problem still existing and not yet committed. Any thing that we can give a hand for speeding up the processing?

Patch reroll via 7.x-2.x GIT. Tested with Drupal 7.0 and PHP 5.3.3. No more error message or WSOD occur.

bc’s picture

Status: Reviewed & tested by the community » Needs review
StatusFileSize
new1.13 KB

re-rolled, let's get d.o to test it!

matason’s picture

Status: Needs review » Reviewed & tested by the community

I applied the patch with "patch -p1 < builderfunction-997464-7.patch" and it fixes the problem, thanks.

drunken monkey’s picture

Please see #1182154-3: Offering to maintain Diff if you'd be willing to take over this project.
Hopefully, this way all these issues with working patches will finally be fixed.

Higarigh’s picture

@ #1 This worked for me too

realityloop’s picture

Status: Reviewed & tested by the community » Fixed

Status: Fixed » Closed (fixed)

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