Index: openacs-4/packages/acs-service-contract/tcl/acs-service-contract-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-service-contract/tcl/acs-service-contract-procs.tcl,v diff -u -r1.24 -r1.25 --- openacs-4/packages/acs-service-contract/tcl/acs-service-contract-procs.tcl 30 Oct 2010 21:43:01 -0000 1.24 +++ openacs-4/packages/acs-service-contract/tcl/acs-service-contract-procs.tcl 8 Dec 2012 18:20:36 -0000 1.25 @@ -38,8 +38,8 @@ @author Lars Pind (lars@collaboraid.biz) @see acs_sc_call } { - if { [exists_and_not_null impl_id] } { - if { [exists_and_not_null impl] } { + if { $impl_id ne "" } { + if { $impl ne "" } { error "Cannot supply both impl and impl_id" } acs_sc::impl::get -impl_id $impl_id -array impl_info @@ -49,7 +49,7 @@ } set contract $impl_info(impl_contract_name) } - if { ![exists_and_not_null impl] || ![exists_and_not_null contract] } { + if { $impl eq "" || $contract eq "" } { error "You must supply either impl_id, or contract and impl to acs_sc::invoke" } return [acs_sc_call -error=$error_p $contract $operation $call_args $impl] @@ -254,13 +254,13 @@ } { set proc_name [acs_sc_generate_name $contract $impl $operation] - if { [llength [info procs $proc_name]] == 1 } { + if { [info commands $proc_name] ne "" } { return [ad_apply $proc_name $arguments] } else { if { $error_p } { error "Operation $operation is not implemented in '$impl' implementation of contract '$contract'" } else { - ns_log warning "ACS-SC: Function Not Found: $proc_name [info procs $proc_name]" + ns_log warning "ACS-SC: Function Not Found: $proc_name [info commands $proc_name]" } return }