Index: openacs-4/packages/rss-support/tcl/rss-generation-service-procs.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/rss-support/tcl/rss-generation-service-procs.tcl,v diff -u -r1.20.2.1 -r1.20.2.2 --- openacs-4/packages/rss-support/tcl/rss-generation-service-procs.tcl 26 Aug 2013 07:57:14 -0000 1.20.2.1 +++ openacs-4/packages/rss-support/tcl/rss-generation-service-procs.tcl 27 Aug 2013 11:25:28 -0000 1.20.2.2 @@ -39,7 +39,7 @@ set datasource [acs_sc::invoke -contract RssGenerationSubscriber -operation datasource -call_args $summary_context_id -impl $impl_name] - if { [empty_string_p $datasource] } { + if { $datasource eq "" } { ns_log Error "Empty datasource returned from $impl_name for context $summary_context_id in rss_gen_report. Probably because the implementation hasn't been bound." return } @@ -65,12 +65,12 @@ # subscriptions table. set extra_sql "" foreach col [list channel_title channel_link] { - if [info exists $col] { + if {[info exists $col]} { append extra_sql ", $col = :$col" } } - set last_ttb [expr [clock seconds] - $start] + set last_ttb [expr {[clock seconds] - $start}] db_dml update_timestamp {} } @@ -84,7 +84,7 @@ set running_path "" foreach dir [split $path /] { append running_path ${dir}/ - if ![file exists $running_path] { + if {![file exists $running_path]} { file mkdir $running_path } } @@ -99,9 +99,9 @@ ns_log Debug "rss_gen_bind: binding impl $impl_id for contract $contract_id" # Don't ask me why, but bind variables don't appear to work # in this nested db operation. - if [catch { + if {[catch { db_exec_plsql bind_impl {} - } errMsg] { + } errMsg]} { ns_log Warning "rss_gen_bind: error binding impl $impl_id for contract $contract_id: $errMsg" } } @@ -119,7 +119,7 @@ } { if {!([info exists summary_context_id] && \ [info exists impl_name])} { - if ![info exists subscr_id] { + if {![info exists subscr_id]} { error "rss_gen_report_dir needs either subscr_id or impl_id+summary_context_id" } else { db_1row subscr_context_and_impl {} @@ -128,7 +128,7 @@ set report_dir [acs_root_dir]/[ad_parameter -package_id [rss_package_id] RssGenOutputDirectory rss-support rss]/$impl_name/${summary_context_id} - if $assert_p { + if {$assert_p} { rss_assert_dir $report_dir } @@ -149,14 +149,14 @@ } { if {!([info exists summary_context_id] && \ [info exists impl_name])} { - if ![info exists subscr_id] { + if {![info exists subscr_id]} { error "rss_gen_report_file needs either subscr_id or impl_id+summary_context_id" } else { db_1row subscr_context_and_impl {} } } - if $assert_p { + if {$assert_p} { set report_dir [rss_gen_report_dir \ -summary_context_id $summary_context_id \ -impl_name $impl_name \