Index: openacs-4/packages/acs-developer-support/tcl/acs-developer-support-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-developer-support/tcl/acs-developer-support-procs.tcl,v diff -u -r1.8.2.3 -r1.8.2.4 --- openacs-4/packages/acs-developer-support/tcl/acs-developer-support-procs.tcl 1 Apr 2003 22:17:23 -0000 1.8.2.3 +++ openacs-4/packages/acs-developer-support/tcl/acs-developer-support-procs.tcl 2 Apr 2003 00:00:53 -0000 1.8.2.4 @@ -68,13 +68,8 @@ ad_proc ds_user_switching_enabled_p {} { Returns whether user-switching is enabled. } { - if { ![nsv_exists ds_properties user_switching_enabled_p] } { - # This might happen when the init file setting up the nsv hasn't - # been sourced yet - return 0 - } else { - return [nsv_get ds_properties user_switching_enabled_p] - } + return [expr {[nsv_exists ds_properties user_switching_enabled_p] && + [nsv_get ds_properties user_switching_enabled_p]}] } ad_proc ds_database_enabled_p {} {