Document: the node context shouldn't contain 'lang'

Node context should be as neutral as possible, in order to help caching.

bzr revid: p_christ@hol.gr-20100629140519-fgxcr2wm5ctg8ywl
This commit is contained in:
P. Christeas 2010-06-29 17:05:19 +03:00
parent d130db349e
commit 74d60c861f
1 changed files with 1 additions and 10 deletions

View File

@ -195,17 +195,8 @@ class document_directory(osv.osv):
"""
if not context:
context = {}
lang = context.get('lang',False)
if not lang:
user = self.pool.get('res.users').browse(cr, uid, uid)
lang = user.context_lang
context['lang'] = lang
try: #just instrumentation
return nodes.get_node_context(cr, uid, context).get_uri(cr, uri)
except Exception,e:
print "exception: ",e
raise
return nodes.get_node_context(cr, uid, context).get_uri(cr, uri)
def _locate_child(self, cr, uid, root_id, uri,nparent, ncontext):