When I enable mimemail module, the email is never sent and I have a white page. I have this error in log : PHP Fatal error: Unsupported operand types in includes/theme.inc on line 1087

The error comes from arguments when theme_webform2pdf_mail2pdf function is called line 583 : Instead of

  $attachment->filecontent = theme('webform2pdf_mail2pdf', $webform2pdf_send2pdf['nid'], $webform2pdf_send2pdf['sid']);

these should be

$attachment->filecontent = theme('webform2pdf_mail2pdf', array('nid'=>$webform2pdf_send2pdf['nid'], 'sid'=> $webform2pdf_send2pdf['sid']));

Here is the patch for this.

Comments

BD3’s picture

I can confirm that the patch fixes the issue for me.

cosmicdreams’s picture

I ran into this error today and can confirm that the above is the proper fix.

cosmicdreams’s picture

Version: 7.x-3.2 » 7.x-4.x-dev
Priority: Normal » Critical

I should add that this is a pretty serious bug. It breaks Webform2PDF silently when using Webform 7.x-4.x and Webform2PDF --dev. This needs to be prioritized.

escalating priority as a result.

tgf’s picture

StatusFileSize
new779 bytes

This bug is still present in dev as of 2015-02-20 and for me results in receiving a blank/empty PDF attachment. I did not notice any errors.

I have included an updated patch file.

anou’s picture

Status: Active » Needs review

I can confirm that patch #4 works for me.
Thanks to you.

mr.york’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

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