Index: openacs-4/packages/dotlrn/www/spam.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/www/spam.tcl,v diff -u -r1.37 -r1.38 --- openacs-4/packages/dotlrn/www/spam.tcl 28 May 2018 14:05:12 -0000 1.37 +++ openacs-4/packages/dotlrn/www/spam.tcl 29 May 2018 08:56:41 -0000 1.38 @@ -98,12 +98,6 @@ set sender_first_names [dict get $user first_names] set sender_last_names [dict get $user last_name] -# names can have single quotes in them, and since they are being selected -# from the database as literals down below, when the sender_info query is -# passed to bulk_mail::new, we have to make sure they are properly quoted -set sender_first_names [db_quote $sender_first_names] -set sender_last_name [db_quote $sender_last_name] - form create spam_message element create spam_message community_id \ @@ -203,8 +197,9 @@ # POSTGRES - change to plural # TODO - what if no rel_types - set safe_community_name [db_quote $community_name] - + + set from_addr $from + set query [db_map sender_info] if {$format eq "html"} { Index: openacs-4/packages/dotlrn/www/spam.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/dotlrn/www/spam.xql,v diff -u -r1.10 -r1.11 --- openacs-4/packages/dotlrn/www/spam.xql 28 May 2018 13:29:57 -0000 1.10 +++ openacs-4/packages/dotlrn/www/spam.xql 29 May 2018 08:56:41 -0000 1.11 @@ -4,10 +4,7 @@ - select :from as from_addr, - :sender_first_names as sender_first_names, - :sender_last_name as sender_last_name, - parties.email, + select parties.email, CASE WHEN acs_objects.object_type = 'user' @@ -39,9 +36,7 @@ where person_id = parties.party_id) ELSE '' - END as last_name, - '$safe_community_name' as community_name, - '$community_url' as community_url + END as last_name from acs_rels, parties, acs_objects