Skip Menu |

This queue is for tickets about the WWW-Mailchimp CPAN distribution.

Report information
The Basics
Id: 83160
Status: resolved
Priority: 0/
Queue: WWW-Mailchimp

People
Owner: Nobody in particular
Requestors: GHENRY [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: Critical
Broken in: 0.007
Fixed in: (no value)



Subject: Does not work on Perl 5.14.2
Trying to debug but I get: Subroutine WWW::Mailchimp::campaignContent redefined at /usr/local/share/perl/5.14.2/WWW/Mailchimp.pm line 275." $mailchimp->listSubscribe( id => 'sdfsd', email_address => 'ghenry@suretec.co.uk' );
From: melmothx [...] gmail.com
The following patch seems to fix this issue: -sub BUILD { - no strict 'refs'; - for my $method (@api_methods) { +no strict 'refs'; +for my $method (@api_methods) { *{$method} = subname $method => sub { shift->_request($method, @_) }; - } } It looks like the BUILD method is called at every new object of the class, and so the subs are redefined each time.
I have uploaded 0.007_01 to address this. On Tue Mar 26 13:16:56 2013, http://melmothx.myopenid.com/ wrote: Show quoted text
> The following patch seems to fix this issue: > > -sub BUILD { > - no strict 'refs'; > - for my $method (@api_methods) { > +no strict 'refs'; > +for my $method (@api_methods) { > *{$method} = subname $method => sub { shift->_request($method, > @_) }; > - } > } > > It looks like the BUILD method is called at every new object of the > class, and so the subs are redefined each time.
registering upload with PAUSE web server POSTing upload for WWW-Mailchimp-0.008.tar.gz to https://pause.perl.org/pause/authenquery PAUSE add message sent ok [200] On Tue Mar 26 14:03:06 2013, arcanez wrote: Show quoted text
> I have uploaded 0.007_01 to address this. > > On Tue Mar 26 13:16:56 2013, http://melmothx.myopenid.com/ wrote:
> > The following patch seems to fix this issue: > > > > -sub BUILD { > > - no strict 'refs'; > > - for my $method (@api_methods) { > > +no strict 'refs'; > > +for my $method (@api_methods) { > > *{$method} = subname $method => sub { shift->_request($method, > > @_) }; > > - } > > } > > > > It looks like the BUILD method is called at every new object of the > > class, and so the subs are redefined each time.
> >