Fix model/view/controller methods to handle stringifiable objects
authorMatt S Trout <mst@shadowcat.co.uk>
Tue, 14 Aug 2012 17:48:43 +0000 (17:48 +0000)
committerMatt S Trout <mst@shadowcat.co.uk>
Tue, 14 Aug 2012 17:48:43 +0000 (17:48 +0000)
commit0ee04045a413235cb1474efcb490039691ef78e6
treee73a08bd3b3580fbb63947d66f5e68e5a14aef7d
parent4995a5cebbc06c813c20daabc8d248247f33cb37
Fix model/view/controller methods to handle stringifiable objects

Previously, uri_for would test to see if its first argument was isa
Catalyst::Controller but then assume any other object was a Catalyst::Action;
this change uses Safe::Isa to check the class in both cases, which is useful
both for string overloading packages such as i18n.pm and HTML::String but also
when a Path::Class::File object is passed during static URI generation.
Changes
lib/Catalyst.pm
t/aggregate/unit_core_uri_for.t