Changeset 2046

Show
Ignore:
Timestamp:
10/24/08 19:56:42
Author:
hsbt
Message:

add encrypt config in global section.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/plagger/lib/Plagger/Plugin.pm

    r1835 r2046  
    7070    my($self, $data, $key) = @_; 
    7171 
     72    my $context = Plagger->context; 
    7273    my $decrypted = Plagger::Crypt->decrypt($data->{$key}); 
    7374    if ($decrypted eq $data->{$key}) { 
    74         Plagger->context->add_rewrite_task($key, $decrypted, Plagger::Crypt->encrypt($decrypted, 'base64')); 
     75       $context->add_rewrite_task($key, $decrypted, Plagger::Crypt->encrypt($decrypted, $context->conf->{encrypt} || 'base64')); 
    7576    } else { 
    7677        $data->{$key} = $decrypted;