package Plagger::Plugin::Cache; use strict; use base qw( Plagger::Plugin ); use DB_File; use Digest::MD5; sub register { my($self, $context) = @_; $context->register_hook( $self, 'update.feed.fixup' => \&update, 'update.fixup' => \&fixup, ); unless ($self->conf->{file}) { $context->error("plase file config"); return; } my %cache; my $a = tie %cache, 'DB_File', $self->conf->{file}; $self->{__cache}