From 0777ee56dd09a2a459074dccda9a8439632ba6e6 Mon Sep 17 00:00:00 2001 From: "mkanat%bugzilla.org" <> Date: Wed, 25 Nov 2009 01:46:35 +0000 Subject: Bug 530746: Create a script that converts extensions from the old format to the new format Patch by Max Kanat-Alexander (module owner) a=mkanat --- extensions/BmpConvert/Extension.pm | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'extensions/BmpConvert') diff --git a/extensions/BmpConvert/Extension.pm b/extensions/BmpConvert/Extension.pm index 29113bd08..ee08e04f0 100644 --- a/extensions/BmpConvert/Extension.pm +++ b/extensions/BmpConvert/Extension.pm @@ -29,10 +29,10 @@ use Image::Magick; our $VERSION = '1.0'; sub attachment_process_data { - my ($self, $params) = @_; - return unless $params->{attributes}->{mimetype} eq 'image/bmp'; + my ($self, $args) = @_; + return unless $args->{attributes}->{mimetype} eq 'image/bmp'; - my $data = ${$params->{data}}; + my $data = ${$args->{data}}; my $img = Image::Magick->new(magick => 'bmp'); # $data is a filehandle. @@ -49,9 +49,9 @@ sub attachment_process_data { } undef $img; - ${$params->{data}} = $data; - $params->{attributes}->{mimetype} = 'image/png'; - $params->{attributes}->{filename} =~ s/^(.+)\.bmp$/$1.png/i; + ${$args->{data}} = $data; + $args->{attributes}->{mimetype} = 'image/png'; + $args->{attributes}->{filename} =~ s/^(.+)\.bmp$/$1.png/i; } __PACKAGE__->NAME; -- cgit v1.2.3-24-g4f1b