Some testing with the new 2.2 client code has turned up a couple of bugs in
template handling:

1. mailfrom/mailto weren't set properly (code used $data{} instead of $in{}
2. period_text was using $data{} instead of $in{}
3. Builk orders would have all of the domains listed (null separated) in
   every message instead of one domain per message.

The patch below fixes all three.

--- cgi/reg_system.cgi~ Tue Sep  5 07:53:56 2000
+++ cgi/reg_system.cgi  Wed Sep  6 23:29:07 2000
@@ -530,10 +530,11 @@
                send_email("$path_templates/message.txt",
                          {
                           %in,
-                          mailfrom => $data{owner_email},
+                          domain => $domain,
+                          mailfrom => $in{owner_email},
                           mailto => $ADMIN_EMAIL,
                           id => $id,
-                          period_text => $REG_PERIODS{$data{period}},
+                          period_text => $REG_PERIODS{$in{period}},
                           reg_type => $reg_type,
                           });
            }
@@ -543,7 +544,8 @@
                send_email("$path_templates/thankyou.txt",
                          {
                           %in,
-                          mailto => $data{owner_email},
+                          domain => $domain,
+                          mailto => $in{owner_email},
                           mailfrom => $ADMIN_EMAIL,
                           id => $id,
                          });
@@ -660,7 +662,7 @@
                       {
                        %in,
                        bulk_transfer_id => 
$register_results->{attributes}->{bulk_transfer_id},
-                       mailfrom => $data{owner_email},
+                       mailfrom => $in{owner_email},
                        mailto => $ADMIN_EMAIL,
                        order_ids => $order_ids,
                        order_errors => $order_errors,
@@ -673,7 +675,7 @@
                       {
                        %in,
                        bulk_transfer_id => 
$register_results->{attributes}->{bulk_transfer_id},
-                       mailto => $data{owner_email},
+                       mailto => $in{owner_email},
                        mailfrom => $ADMIN_EMAIL,
                        order_ids => $order_ids,
                       });

Reply via email to