Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: map return to array reference

by johngg (Abbot)
on Jan 24, 2007 at 17:06 UTC ( #596289=note: print w/ replies, xml ) Need Help??


in reply to map return to array reference

The string "6" is a good clue, since your Dumper output shows 6 files. $self->_getGood() returns an array so there's no need to wrap it in @{...}. Try

my $files_to_send = map {"$stage/$_.pdf"} $self->_getGood();

Cheers,

JohnGG

Update: Doh! My eyes saw $files_to_send, my brain translated to @files_to_send. You could change $self->_getGood() to return the array reference instead, return $self->{_good};

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://596289]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others chilling in the Monastery: (6)
As of 2016-06-30 05:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My preferred method of making French fries (chips) is in a ...











    Results (389 votes). Check out past polls.