[FIX] res.config: ensure there is a context before checking its content

lp bug: https://launchpad.net/bugs/891187 fixed

bzr revid: xmo@openerp.com-20111117120318-r9mns1w1vh9ea22b
This commit is contained in:
Xavier Morel
2011-11-17 13:03:18 +01:00
parent 03ef4eb14c
commit c418cfcb9d
+1 -1
View File
@@ -71,7 +71,7 @@ class res_config_configurable(osv.osv_memory):
res['nodestroy'] = False
return res
#if there is no next action and if html is in the context: reload instead of closing
if 'html' in context:
if context and 'html' in context:
return {'type' : 'ir.actions.reload'}
return {'type' : 'ir.actions.act_window_close'}