document: fix recursive (tree) resource directories
authorP. Christeas <p_christ@hol.gr>
Wed, 27 Oct 2010 10:23:23 +0000 (13:23 +0300)
committerP. Christeas <p_christ@hol.gr>
Wed, 27 Oct 2010 10:23:23 +0000 (13:23 +0300)
The 'node_res_obj' has been the right class to use for the intermediate
nodes, ever since. The assertion that it should only apply to static
dirs was wrong.

bzr revid: p_christ@hol.gr-20101027102323-qewjjzzudj0zz643

addons/document/document_directory.py
addons/document_webdav/document_webdav.py

index c4df8a7..907a3aa 100644 (file)
@@ -190,7 +190,6 @@ class document_directory(osv.osv):
             dbro = self.browse(cr, uid, ids, context=context)
 
         if dynamic:
-            assert dbro.type == 'directory'
             return nodes.node_res_obj
         elif dbro.type == 'directory':
             return nodes.node_dir
index 28b70c8..2e1eb8c 100644 (file)
@@ -37,7 +37,6 @@ class document_davdir(osv.osv):
             dbro = self.browse(cr, uid, ids, context=context)
 
         if dynamic:
-            assert dbro.type == 'directory'
             return nodes.node_res_obj
         elif dbro.type == 'directory':
             return nodes.node_dir