/[notice-sender]/trunk/sender.pl
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /trunk/sender.pl

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 22 by dpavlin, Sun May 15 21:52:56 2005 UTC revision 23 by dpavlin, Sun May 15 22:12:31 2005 UTC
# Line 120  B<This seems somewhat cludgy, and it wil Line 120  B<This seems somewhat cludgy, and it wil
120                  chomp;                  chomp;
121                  next if (/^#/ || /^\s*$/);                  next if (/^#/ || /^\s*$/);
122                  my ($email, $name) = split(/\s+/,$_, 2);                  my ($email, $name) = split(/\s+/,$_, 2);
123                  $name ||= '';                  $added++ if ($nos->add_member_to_list( email => $email, name => $name, list => $add_opt ));
                 if (! Email::Valid->address($email)) {  
                         print "SKIPPING $name <$email>\n";  
                         next;  
                 }  
                 print "# $name <$email>\n";  
                 my $this_user = $users->find_or_create({  
                         email => $email,  
                         full_name => $name,  
                 }) || die "can't find or create member\n";  
                 my $user_on_list = $user_list->find_or_create({  
                         user_id => $this_user->id,  
                         list_id => $list->id,  
                 }) || die "can't add user to list";  
                 $added++;  
         }  
   
         foreach my $c_name ($loader->tables) {  
                 my $c = $loader->find_class($c_name)|| die "can't find $c_name";  
                 $c->dbi_commit();  
124          }          }
125    
126          print "list ",$list->name," has $added users\n";          print "list ",$list->name," has $added users\n";

Legend:
Removed from v.22  
changed lines
  Added in v.23

  ViewVC Help
Powered by ViewVC 1.1.26