X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FCatalyst.pm;h=3471a6c4bdfa9cf16afadfc555aa6fdfe95eccf8;hb=6b2a933b5b3820e494f9b5804c7c2eb6083bcf09;hp=cef7ac7be4989384fcde50e97e808fce8304230d;hpb=5baa3bbcb8bea403665bceaa82f819905f0b501f;p=catagits%2FCatalyst-Runtime.git diff --git a/lib/Catalyst.pm b/lib/Catalyst.pm index cef7ac7..3471a6c 100644 --- a/lib/Catalyst.pm +++ b/lib/Catalyst.pm @@ -862,11 +862,19 @@ loads and instantiates the given class. MyApp->plugin( 'prototype', 'HTML::Prototype' ); $c->prototype->define_javascript_functions; + +B This method of adding plugins is deprecated. The ability +to add plugins like this B in a Catalyst 5.9. +Please do not use this functionality in new code. =cut sub plugin { my ( $class, $name, $plugin, @args ) = @_; + + # See block comment in t/unit_core_plugin.t + $class->log->debug(qq/Adding plugin using the ->plugin method is deprecated, and will be removed in Catalyst 5.9/); + $class->_register_plugin( $plugin, 1 ); eval { $plugin->import };