From: André Walker Date: Wed, 10 Aug 2011 18:01:23 +0000 (-0300) Subject: flush_request_services() is a bad idea X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=3fbe4809367885c128b24205a5a6887a60bddba5;hp=4e4e003e3c915e6e4d3b9f2a97c0d458ffa4ae9c;p=catagits%2FCatalyst-Runtime.git flush_request_services() is a bad idea --- diff --git a/lib/Catalyst/IOC/Container.pm b/lib/Catalyst/IOC/Container.pm index 3359ec9..0a0407d 100644 --- a/lib/Catalyst/IOC/Container.pm +++ b/lib/Catalyst/IOC/Container.pm @@ -694,19 +694,6 @@ sub expand_component_module { return Devel::InnerPackage::list_packages( $module ); } -# copied from stevan's OX -sub flush_request_services { - my $self = shift; - my @services = $self->get_service_list; - - foreach my $service (@services) { - my $injection = $self->get_service($service); - if ($injection->does('Catalyst::IOC::LifeCycle::Request')) { - $injection->flush_instance; - } - } -} - 1; __END__ @@ -914,8 +901,6 @@ Finds components that match a given regexp. Used internally, by find_component. Components found by C will be passed to this method, which is expected to return a list of component (package) names to be set up. -=head2 flush_request_services - =head2 setup_components =head1 AUTHORS