[FIX] fix exception check

bzr revid: alexandre.fayolle@camptocamp.com-20130523090055-4m418aninaczbzcy
This commit is contained in:
Alexandre Fayolle
2013-05-23 11:00:55 +02:00
parent cebc5dd29c
commit cea92690f7
+2 -2
View File
@@ -19,7 +19,7 @@
#
##############################################################################
from openerp.osv import fields, osv
from openerp.osv import fields, osv, orm
from openerp.tools.translate import _
class stock_fill_inventory(osv.osv_memory):
@@ -31,7 +31,7 @@ class stock_fill_inventory(osv.osv_memory):
location = self.pool.get('ir.model.data').get_object(cr, uid, 'stock', 'stock_location_stock')
location.check_access_rule('read', context=context)
location_id = location.id
except ValueError, e:
except (ValueError, orm.except_orm), e:
return False
return location_id or False