Document: fix creating of empty files.

For an empty file, the interface (eg. webdav) could ask to create with
data=None. Allow that.

bzr revid: p_christ@hol.gr-20100623140709-m11r40kk2dl9okvo
This commit is contained in:
P. Christeas
2010-06-23 17:07:09 +03:00
parent 1b6970ec3f
commit df40ff60dc
+2 -1
View File
@@ -339,7 +339,8 @@ class node_dir(node_database):
fil_id = fil_obj.create(cr, uid, val, context=ctx)
fil = fil_obj.browse(cr, uid, fil_id, context=ctx)
fnode = node_file(path, self, self.context, fil)
fnode.set_data(cr, data, fil)
if data is not None:
fnode.set_data(cr, data, fil)
return fnode
def get_etag(self, cr):