Problem/Motivation

In rare cases, it's possible for a node_save() of a new node or node revision to be rolled back during the course of a single page request (via db_transaction()->rollback())... In such cases, the node will no longer exist in the database, but will still exist in PHP variables or static cache. When we hit Workbench Moderation's shutdown function, the node will be passed through, but when it attempts to load the live revision, it will be unable to do so... It stumbles through some PHP notices (creating default object), before attempting to save a half-formed node and dies on an uncaught exception.

Proposed resolution

Workbench moderation just needs a little bit of sanity checking in its shutdown function to catch this rare situation.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

iamEAP created an issue. See original summary.

iamEAP’s picture

iamEAP’s picture

Issue summary: View changes