[Rt-commit] r11223 - rt/branches/3.8-TESTING/lib/RT

ruz at bestpractical.com ruz at bestpractical.com
Wed Mar 26 22:43:58 EDT 2008


Author: ruz
Date: Wed Mar 26 22:43:58 2008
New Revision: 11223

Modified:
   rt/branches/3.8-TESTING/lib/RT/Base.pm

Log:
* we need Carp::longmess instead of cluck

Modified: rt/branches/3.8-TESTING/lib/RT/Base.pm
==============================================================================
--- rt/branches/3.8-TESTING/lib/RT/Base.pm	(original)
+++ rt/branches/3.8-TESTING/lib/RT/Base.pm	Wed Mar 26 22:43:58 2008
@@ -46,8 +46,8 @@
 # 
 # END BPS TAGGED BLOCK }}}
 package RT::Base;
-use Carp;
-use Scalar::Util;
+use Carp ();
+use Scalar::Util ();
 
 use strict;
 use vars qw(@EXPORT);
@@ -102,7 +102,7 @@
         my $msg = "$self was created without a CurrentUser."
             ." Any RT object which is subclass of RT::Base must be created"
             ." with a RT::CurrentUser or a RT::User obejct as the first argument.";
-        $msg .= "\n". Carp::cluck() if @_;
+        $msg .= "\n". Carp::longmess() if @_;
 
         $RT::Logger->err( $msg );
         return $self->{'user'} = undef;
@@ -146,7 +146,6 @@
         return $user->loc(@_);
     }
     else {
-        require Carp;
         Carp::confess("No currentuser");
         return ("Critical error:$self has no CurrentUser", $self);
     }
@@ -158,7 +157,6 @@
         return $user->loc_fuzzy(@_);
     }
     else {
-        use Carp;
         Carp::confess("No currentuser");
         return ("Critical error:$self has no CurrentUser", $self);
     }


More information about the Rt-commit mailing list