When you updating a merci nodes not from the node_form, but for example on content page by publishing or unpublishing a bunch of nodes, you get a following notices:

Notice: Undefined property: stdClass::$revision in merci_update() (line 259 of /var/www/sfcenter/sites/all/modules/contrib/merci/merci.module).
Notice: Undefined property: stdClass::$revision in merci_add_reservation_items() (line 1123 of /var/www/sfcenter/sites/all/modules/contrib/merci/includes/api.inc).
Notice: Undefined property: stdClass::$merci_original_reservation_status in _merci_email_check_send_email() (line 198 of /var/www/sfcenter/sites/all/modules/contrib/merci_email/merci_email.module).

Comments

vlkff’s picture

StatusFileSize
new1.27 KB

do not use it, the right patch is a next one

vlkff’s picture

Status: Active » Needs review
StatusFileSize
new1.27 KB

this is a right one -)

Status: Needs review » Needs work

The last submitted patch, merci_fix-updating-notices_1525348-1.patch, failed testing.

darrick’s picture

I've committed a fix here: http://drupalcode.org/project/merci.git/patch/ea35abc

I didn't go your route but appreciate the patch none the less. I ended up following what is done in node_save which checks to see if node->revision is empty or not.

darrick’s picture

Status: Needs work » Fixed

Status: Fixed » Closed (fixed)

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