From ee725b0b84d2b741e2891f6e1dab93da2ca42731 Mon Sep 17 00:00:00 2001 From: Colin Kuskie Date: Wed, 7 Apr 2010 15:24:25 -0700 Subject: [PATCH] Moose override for cut (Post only) --- lib/WebGUI/Asset/Post.pm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/WebGUI/Asset/Post.pm b/lib/WebGUI/Asset/Post.pm index 4026f8838..feb5fee65 100644 --- a/lib/WebGUI/Asset/Post.pm +++ b/lib/WebGUI/Asset/Post.pm @@ -291,7 +291,7 @@ the parent thread. =cut -sub cut { +override cut => sub { my $self = shift; # Fetch the Thread and CS before cutting the asset. @@ -299,7 +299,7 @@ sub cut { my $cs = $thread->getParent; # Cut the asset - my $result = $self->SUPER::cut; + my $result = super(); # If a post is being cut update the thread reply count first if ($thread->getId ne $self->getId) { @@ -311,7 +311,7 @@ sub cut { $self->_fixReplyCount( $cs ); return $result; -} +}; #-------------------------------------------------------------------