[FIX] google_drive: avoid AccessError when reading filters
If a config use a private filter, others users can't read it due to record rules on filters.
This commit is contained in:
parent
d951591b62
commit
fe73fc442c
|
@ -160,7 +160,7 @@ class config(osv.Model):
|
|||
# check if a model is configured with a template
|
||||
config_ids = self.search(cr, uid, [('model_id', '=', res_model)], context=context)
|
||||
configs = []
|
||||
for config in self.browse(cr, uid, config_ids, context=context):
|
||||
for config in self.browse(cr, SUPERUSER_ID, config_ids, context=context):
|
||||
if config.filter_id:
|
||||
if (config.filter_id.user_id and config.filter_id.user_id.id != uid):
|
||||
#Private
|
||||
|
|
Loading…
Reference in New Issue