Index: openacs-4/packages/acs-tcl/tcl/tcl-documentation-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-tcl/tcl/tcl-documentation-procs.tcl,v diff -u -r1.30.2.12 -r1.30.2.13 --- openacs-4/packages/acs-tcl/tcl/tcl-documentation-procs.tcl 5 Aug 2014 17:45:35 -0000 1.30.2.12 +++ openacs-4/packages/acs-tcl/tcl/tcl-documentation-procs.tcl 6 Aug 2014 09:27:00 -0000 1.30.2.13 @@ -781,7 +781,7 @@ return -code error "[_ acs-tcl.lt_The_-requires_element_1]" } set req_filter [lindex $parts_v 1] - if { $req_filter eq "array" || $req_filter eq "multiple" } { + if { $req_filter in {array multiple} } { return -code error "You can't require \"$req_name:$req_filter\" for block \"$name\"." } } @@ -1071,12 +1071,24 @@ set code [lindex $apc_validation_blocks($validation_name) 1] set dependencies_met_p 1 - foreach dependency $dependencies { - if { ![info exists ::ad_page_contract_validations_passed($dependency)] } { - set dependencies_met_p 0 - break - } - } + # + # With the following code, the page contract spec + # (name+filter) in "requires" has to be fully identical + # with the name listed in the query variable + # section. Otherweise, the validation is skipped. + # + # foreach dependency $dependencies { + # if { ![info exists ::ad_page_contract_validations_passed($dependency)] } { + # set dependencies_met_p 0 + # break + # } + # } + # + # It is sufficient to check, whether the earlier section + # haven't returned errors, in which case the detailed + # validation is not necessary. + # + if {[ad_complaints_count]>0} {set dependencies_met_p 0} if { $dependencies_met_p } {