On 05/02/2014 01:03 PM, Warren Young wrote:
This page claims params() returns a hashref, always:

    https://metacpan.org/pod/Dancer::Request#params

There is no #params anchor on that page, so I'm not sure what you're looking at.


Not true.  It only does so in scalar context.  Thus:

    myfunction(params);

will pass myfunction a hash which gets flattened to an array, not a hashref. The fix is myfunction(scalar params);

This is documented under https://metacpan.org/pod/Dancer::Request#params-source, as you noted. Since that is the only section related to params on the entire page, I don't see the issue.


Also, this link from that section:

    https://metacpan.org/pod/Dancer::Request#params-source

is missing the "-source" bit at the end.

I see "-source" right there in the link: https://metacpan.org/pod/Dancer::Request#params-source. Am I missing something? I must be looking at a completely different page than you are. Or maybe I've just had too much to drink ;)
_______________________________________________
dancer-users mailing list
[email protected]
http://lists.preshweb.co.uk/mailman/listinfo/dancer-users

Reply via email to