Skip Menu |

This queue is for tickets about the Maypole CPAN distribution.

Report information
The Basics
Id: 14073
Status: resolved
Priority: 0/
Queue: Maypole

People
Owner: TEEJAY [...] cpan.org
Requestors: kdiment [...] uow.edu.au
Cc:
AdminCc:

Bug Information
Severity: Normal
Broken in: 2.10
Fixed in: 2.11



Subject: documentation bug in Maypole::Manual::Request
In the section of Maypole::Manual::Request that deals with Net::Amazon there is a missing curly bracket. See below --cut-- Solution: Munge the contents of " $r->params " before jumping to the original "do_edit" routine. For instance, in this method, we use a Net::Amazon object to fill in some fields of a database row based on an ISBN: sub create_from_isbn :Exported { my ($self, $r) = @_; my $response = $ua->search(asin => $r->params->{isbn}); my ($prop) = $response->properties; # Rewrite the CGI parameters with the ones from Amazon #--problem starts on line below @{$r->params->{qw(title publisher author year)} = ($prop->title, $prop->publisher, (join "/", $prop->authors()), $prop->year()); # And jump to the usual edit/create routine $self->do_edit($r); } --cut- there is a missing right curly bracket somewhere between @{$r and $prop-year()) - it's very difficult to tell where. I think that this part of the manual needs to be rewritten using code with much greater clarity and no syntax errors. Cheers Kieren
[guest - Tue Aug 9 06:55:16 2005]: Show quoted text
> In the section of Maypole::Manual::Request that deals with Net::Amazon > there is a missing curly bracket. See below > > > --cut-- > Solution: Munge the contents of " $r->params " before jumping to the > original "do_edit" routine. For instance, in this method, we > use a > Net::Amazon object to fill in some fields of a database row > based on an > ISBN: > > sub create_from_isbn :Exported { > my ($self, $r) = @_; > my $response = $ua->search(asin => $r->params->{isbn}); > my ($prop) = $response->properties; > # Rewrite the CGI parameters with the ones from Amazon > #--problem starts on line below > @{$r->params->{qw(title publisher author year)} = > ($prop->title, > $prop->publisher, > (join "/", $prop->authors()), > $prop->year()); > # And jump to the usual edit/create routine > $self->do_edit($r); > } > --cut- > > there is a missing right curly bracket somewhere between @{$r and > $prop-year()) - it's very difficult to tell where. I think that > this part of the manual needs to be rewritten using code with much > greater clarity and no syntax errors. > > Cheers > > Kieren
amended in SVN 369