-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

[EMAIL PROTECTED] writes:
>Author: felicity
>Date: Sun Dec  4 20:46:43 2005
>New Revision: 353986
>
>URL: http://svn.apache.org/viewcvs?rev=353986&view=rev
>Log:
>when evaltests move to plugins, the object reference is not what it once was

oh crap.  This may be a bad thing.

Should we define a new API for plugins to define eval tests that uses the
old, EvalTests-compatible argument order?

- --j.

>Modified:
>    spamassassin/rules/trunk/sandbox/felicity/sandbox-felicity.pm
>
>Modified: spamassassin/rules/trunk/sandbox/felicity/sandbox-felicity.pm
>URL: 
>http://svn.apache.org/viewcvs/spamassassin/rules/trunk/sandbox/felicity/sandbox-felicity.pm?rev=353986&r1=353985&r2=353986&view=diff
>==============================================================================
>--- spamassassin/rules/trunk/sandbox/felicity/sandbox-felicity.pm (original)
>+++ spamassassin/rules/trunk/sandbox/felicity/sandbox-felicity.pm Sun Dec  4 
>20:46:43 2005
>@@ -44,9 +44,9 @@
> }
> 
> sub check_iframe_src {
>-  my ($self) = @_;
>+  my ($self, $pms) = @_;
> 
>-  while (my($k,$v) = each %{$self->{html}->{uri_detail}}) {
>+  while (my($k,$v) = each %{$pms->{html}->{uri_detail}}) {
>     return 1 if $v->{types}->{iframe};
>   }
> 
>@@ -54,12 +54,12 @@
> }
> 
> sub check_from_format {
>-  my ($self) = @_;
>+  my ($self, $pms) = @_;
> 
>-  my $name = $self->get('From:name') || return;
>+  my $name = $pms->get('From:name') || return;
>   return if ($name !~ m/^[A-Z][a-z]+\.[A-Z][a-z]+\@/);
> 
>-  my $addr = $self->get('From:addr') || return;
>+  my $addr = $pms->get('From:addr') || return;
>   return if ($addr !~ m/^[A-Z][a-z]+\.[A-Z][a-z]+\@/);
> 
>   return if ($name eq $addr);
>@@ -67,16 +67,16 @@
> }
> 
> sub subject_length {
>-  my ($self, $min, $max) = @_;
>-  my $len = length($self->get('Subject'));
>+  my ($self, $pms, $min, $max) = @_;
>+  my $len = length($pms->get('Subject'));
>   return($len < $max && $len >= $min);
> }
> 
> sub check_html_uri_only {
>-  my ($self) = @_;
>+  my ($self, $pms) = @_;
> 
>   # Find out if there are any  multipart/alternative parts in the message
>-  my @ma = $self->{msg}->find_parts([EMAIL PROTECTED]/[EMAIL PROTECTED]);
>+  my @ma = $pms->{msg}->find_parts([EMAIL PROTECTED]/[EMAIL PROTECTED]);
> 
>   # If there are no multipart/alternative sections, skip this test.
>   return if ([EMAIL PROTECTED]);
>@@ -84,7 +84,7 @@
>   # At this point, we're not actually checking the alternates, just the entire
>   # message.
>   my $return = 0;
>-  while (my($k,$v) = each %{$self->{html}->{uri_detail}}) {
>+  while (my($k,$v) = each %{$pms->{html}->{uri_detail}}) {
>     $return = 1; # make sure there's at least 1 URI
>     return 0 if ($v->{types}->{parsed});
>   }
>
>
>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.1 (GNU/Linux)
Comment: Exmh CVS

iD8DBQFDlI/KMJF5cimLx9ARArAiAJ4shew9lwZKK31R9sVPb/4bO2gD9gCeINBO
mBdxp0EHHE0baC1JX/rMaBs=
=HU61
-----END PGP SIGNATURE-----

Reply via email to