diff options
| author | ron@tinyerp.com <> | 2010-12-17 11:43:37 +0530 |
|---|---|---|
| committer | ron@tinyerp.com <> | 2010-12-17 11:43:37 +0530 |
| commit | dfd44bd10e2d4492c6f5f82338caca87bc34113d (patch) | |
| tree | 9f6babd6932c4354d0d51835f81d2f270fe19b82 /addons/document/document_storage.py | |
| parent | 2646ac2706cd3dbd62968c52b7fb933978a786a4 (diff) | |
| parent | 4e307d022c8fbdba848b8a4f57d668a4b6bd036f (diff) | |
[MERGE]Merged :trunk-dev-addons2
bzr revid: ron@tinyerp.com-20101217061337-pgiwc9jappuoryv2
Diffstat (limited to 'addons/document/document_storage.py')
| -rw-r--r-- | addons/document/document_storage.py | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/addons/document/document_storage.py b/addons/document/document_storage.py index aa2edb6b411..b61b7fd65fc 100644 --- a/addons/document/document_storage.py +++ b/addons/document/document_storage.py @@ -422,9 +422,7 @@ class document_storage(osv.osv): optionally, fil_obj could point to the browse object of the file (ir.attachment) """ - if not context: - context = {} - boo = self.browse(cr, uid, id, context) + boo = self.browse(cr, uid, id, context=context) if not boo.online: raise IOError(errno.EREMOTE, 'medium offline') @@ -439,7 +437,7 @@ class document_storage(osv.osv): """ if context is None: context = {} - boo = self.browse(cr, uid, id, context) + boo = self.browse(cr, uid, id, context=context) if not boo.online: raise IOError(errno.EREMOTE, 'medium offline') @@ -540,9 +538,7 @@ class document_storage(osv.osv): This function MUST be used from an ir.attachment. It wouldn't make sense to store things persistently for other types (dynamic). """ - if not context: - context = {} - boo = self.browse(cr, uid, id, context) + boo = self.browse(cr, uid, id, context=context) if fil_obj: ira = fil_obj else: |
