Merge lp://qastaging/~halls/poweremail/no-sig-fix into lp://qastaging/poweremail/trunk

Proposed by Chris Halls
Status: Merged
Merged at revision: not available
Proposed branch: lp://qastaging/~halls/poweremail/no-sig-fix
Merge into: lp://qastaging/poweremail/trunk
Diff against target: 14 lines (+3/-2)
1 file modified
poweremail_send_wizard.py (+3/-2)
To merge this branch: bzr merge lp://qastaging/~halls/poweremail/no-sig-fix
Reviewer Review Type Date Requested Status
Sharoon Thomas http://openlabs.co.in Approve
Review via email: mp+22087@code.qastaging.launchpad.net

Description of the change

Hi, I set up poweremail as I said to you I would do after your great presentation at the conference :)
I tried it with a user without a signature set and got an exception:

ERROR:web-services:[16]: Traceback (most recent call last):
[...]
ERROR:web-services:[22]: return getattr(object, method)(cr, uid, *args, **kw)
ERROR:web-services:[23]: File "/usr/lib/openerp-server/addons/poweremail/poweremail_send_wizard.py", line 161, in send_mail
ERROR:web-services:[24]: mailid = self.save_to_mailbox(cr, uid, ids, context)
ERROR:web-services:[25]: File "/usr/lib/openerp-server/addons/poweremail/poweremail_send_wizard.py", line 211, in save_to_mailbox
ERROR:web-services:[26]: vals['pem_body_text'] = tools.ustr(vals['pem_body_text'] or '') + signature
ERROR:web-services:[27]: TypeError: coercing to Unicode: need string or buffer, bool found

This fixes that by only appending the signature if one is set.

To post a comment you must log in.
Revision history for this message
Sharoon Thomas http://openlabs.co.in (sharoonthomas) wrote :

I think the patch is pretty trivial.

So merging with the trunk.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.