From b027e6df0b17cc520369326b7ccbb6127bf63056 Mon Sep 17 00:00:00 2001 From: Invitu Date: Sat, 29 Oct 2016 09:41:24 -1000 Subject: [PATCH] [FIX] Fix travis --- base_phone/fields.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/base_phone/fields.py b/base_phone/fields.py index 24ec7a0..e9e2b34 100644 --- a/base_phone/fields.py +++ b/base_phone/fields.py @@ -121,8 +121,8 @@ def write(self, vals): # Odoo generate a write() with the ID of the country as unicode !!! # example : vals = {u'country_id': u'9'} # So we have to convert it to an integer before browsing - if vals[u'country_id']: - vals[u'country_id'] = int(vals[u'country_id']) + if vals['country_id']: + vals['country_id'] = int(vals['country_id']) loc_vals = convert_all_phone_fields( record, vals, fields_to_convert) original_write(record, loc_vals) @@ -140,8 +140,8 @@ def create(self, vals): # Odoo generate a create() with the ID of the country as unicode !!! # example : vals = {u'country_id': u'9'} # So we have to convert it to an integer before browsing - if vals[u'country_id']: - vals[u'country_id'] = int(vals[u'country_id']) + if vals['country_id']: + vals['country_id'] = int(vals['country_id']) vals = convert_all_phone_fields(self, vals, fields_to_convert) return original_create(self, vals)