Index: openacs-4/packages/file-storage/tcl/file-storage-procs-postgresql.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/file-storage/tcl/file-storage-procs-postgresql.xql,v diff -u -r1.29.2.3 -r1.29.2.4 --- openacs-4/packages/file-storage/tcl/file-storage-procs-postgresql.xql 7 Mar 2003 00:11:52 -0000 1.29.2.3 +++ openacs-4/packages/file-storage/tcl/file-storage-procs-postgresql.xql 5 May 2003 10:09:12 -0000 1.29.2.4 @@ -81,7 +81,7 @@ select count(*) from cr_items c1, cr_items c2 - where c2.item_id = file_storage__get_parent_id(:item_id) + where c2.item_id = :item_id and c1.tree_sortkey between c2.tree_sortkey and tree_right(c2.tree_sortkey) and not acs_permission__permission_p(c1.item_id, :user_id, :privilege)