From 2ca20a96c99111f06d814b341d1f8664a6d2dd53 Mon Sep 17 00:00:00 2001 From: Udo Spallek Date: Thu, 22 Dec 2011 12:15:03 +0100 Subject: [PATCH] Format report field to buffer type for migration issue2354 review213002 --- invoice.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/invoice.py b/invoice.py index adb6855a7e..88619b547f 100644 --- a/invoice.py +++ b/invoice.py @@ -194,7 +194,7 @@ class Invoice(ModelWorkflow, ModelSQL, ModelView): 'FROM "' + self._table + '"') for invoice_id, report in cursor.fetchall(): if report: - report = base64.decodestring(str(report)) + report = buffer(base64.decodestring(str(report))) cursor.execute('UPDATE "' + self._table + '" ' 'SET invoice_report_cache = %s ' 'WHERE id = %s', (report, invoice_id))