Index: openacs-4/packages/xowiki/tcl/xowiki-uploader-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowiki/tcl/xowiki-uploader-procs.tcl,v diff -u -r1.3.2.2 -r1.3.2.3 --- openacs-4/packages/xowiki/tcl/xowiki-uploader-procs.tcl 1 Jul 2020 19:31:58 -0000 1.3.2.2 +++ openacs-4/packages/xowiki/tcl/xowiki-uploader-procs.tcl 26 Aug 2020 18:35:00 -0000 1.3.2.3 @@ -27,7 +27,7 @@ error "not implemented" } } - + nx::Class create ::xowiki::UploadFile -superclass ::xowiki::Upload { # # Class for storing files as xowiki::File instances. @@ -70,7 +70,7 @@ # set package_id [${:parent_object} package_id] set parent_id [${:parent_object} item_id] - + set photo_object [::$package_id get_page_from_name -name en:${:file_name} -parent_id $parent_id] if {$photo_object ne ""} { # @@ -83,14 +83,14 @@ $f content-type ${:content_type} $f set tmpfile ${:tmpfile} $f convert_to_internal - $photo_object save + $photo_object save } else { # # Create a new page instance of photo.form. # ns_log notice "new Photo ${:file_name}" - set photoFormObj [::xowiki::Weblog instantiate_forms \ - -parent_id $parent_id -forms en:photo.form -package_id $package_id] + set photoFormObj [::$package_id instantiate_forms \ + -parent_id $parent_id -forms en:photo.form] set photo_object [$photoFormObj create_form_page_instance \ -name en:${:file_name} \ -nls_language en_US \ @@ -107,7 +107,7 @@ $f set tmpfile ${:tmpfile} $f convert_to_internal } - + return {status_code 201 message created} } }