Index: openacs-4/packages/xowf/lib/edit-interaction.wf =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/xowf/lib/edit-interaction.wf,v diff -u -r1.1.2.14 -r1.1.2.15 --- openacs-4/packages/xowf/lib/edit-interaction.wf 6 May 2022 14:55:55 -0000 1.1.2.14 +++ openacs-4/packages/xowf/lib/edit-interaction.wf 12 May 2023 06:36:06 -0000 1.1.2.15 @@ -81,7 +81,16 @@ set item_type [$obj property item_type] if {$item_type eq ""} { set item_type [ns_queryget p.item_type] - if {$item_type eq ""} { + + # validate item_type + set item_types {} + foreach class [::xowiki::formfield::TestItemField info subclass -closure] { + if {[$class exists item_type]} { + lappend item_types {*}[$class set item_type] + } + } + + if {$item_type eq "" || $item_type ni $item_types} { set item_type ShortText } $obj set_property -new 1 item_type $item_type