summaryrefslogtreecommitdiffstats
path: root/extensions/BmpConvert
diff options
context:
space:
mode:
authormkanat%bugzilla.org <>2009-11-25 02:46:35 +0100
committermkanat%bugzilla.org <>2009-11-25 02:46:35 +0100
commit0777ee56dd09a2a459074dccda9a8439632ba6e6 (patch)
treeb9d2a7e8a799072cb29626a82a08bd459911c2a6 /extensions/BmpConvert
parent823e59691fc7224ecca6d95076996fe38383bd64 (diff)
downloadbugzilla-0777ee56dd09a2a459074dccda9a8439632ba6e6.tar.gz
bugzilla-0777ee56dd09a2a459074dccda9a8439632ba6e6.tar.xz
Bug 530746: Create a script that converts extensions from the old format to the new format
Patch by Max Kanat-Alexander <mkanat@bugzilla.org> (module owner) a=mkanat
Diffstat (limited to 'extensions/BmpConvert')
-rw-r--r--extensions/BmpConvert/Extension.pm12
1 files changed, 6 insertions, 6 deletions
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;