From c4eb3b162e711e5ceda601a0f12b0277f99139b2 Mon Sep 17 00:00:00 2001 From: Moritz Bunkus Date: Fri, 31 Aug 2012 18:06:33 +0200 Subject: [PATCH] =?utf8?q?SL::Controller::Base::=5Fcontroller=5Fname=20f?= =?utf8?q?=C3=BCr=20Kontrollernamen=20mit=20::=20im=20lokalen=20Part?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- SL/Controller/Base.pm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/SL/Controller/Base.pm b/SL/Controller/Base.pm index 4dace86ed..1188ffe8b 100644 --- a/SL/Controller/Base.pm +++ b/SL/Controller/Base.pm @@ -204,7 +204,9 @@ sub _run_action { } sub _controller_name { - return (split(/::/, ref($_[0]) || $_[0]))[-1]; + my $class = ref($_[0]) || $_[0]; + $class =~ s/^SL::Controller:://; + return $class; } sub _dispatch { -- 2.20.1