projects
/
freeside.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
RT 4.0.19
[freeside.git]
/
rt
/
lib
/
RT.pm
diff --git
a/rt/lib/RT.pm
b/rt/lib/RT.pm
index
da60ef7
..
0f0c79a
100644
(file)
--- a/
rt/lib/RT.pm
+++ b/
rt/lib/RT.pm
@@
-2,7
+2,7
@@
#
# COPYRIGHT:
#
#
# COPYRIGHT:
#
-# This software is Copyright (c) 1996-201
3
Best Practical Solutions, LLC
+# This software is Copyright (c) 1996-201
4
Best Practical Solutions, LLC
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
# <sales@bestpractical.com>
#
# (Except where explicitly superseded by other copyright notices)
@@
-181,8
+181,8
@@
up logging|/InitLogging>, and L<loads plugins|/InitPlugins>.
=cut
sub Init {
=cut
sub Init {
-
- my
@arg = @_
;
+ shift if @_%2; # code is inconsistent about calling as method
+ my
%args = (@_)
;
CheckPerlRequirements();
CheckPerlRequirements();
@@
-191,8
+191,8
@@
sub Init {
#Get a database connection
ConnectToDatabase();
InitSystemObjects();
#Get a database connection
ConnectToDatabase();
InitSystemObjects();
- InitClasses();
- InitLogging(
@arg
);
+ InitClasses(
%args
);
+ InitLogging(
%args
);
InitPlugins();
RT::I18N->Init;
RT->Config->PostLoadCheck;
InitPlugins();
RT::I18N->Init;
RT->Config->PostLoadCheck;
@@
-264,7
+264,7
@@
sub InitLogging {
my ($package, $filename, $line) = caller($frame);
$p{'message'} =~ s/(?:\r*\n)+$//;
my ($package, $filename, $line) = caller($frame);
$p{'message'} =~ s/(?:\r*\n)+$//;
- return "[". gmtime(time) ."] [". $p{'level'} ."]: "
+ return "[
$$] [
". gmtime(time) ."] [". $p{'level'} ."]: "
. $p{'message'} ." ($filename:$line)\n";
};
. $p{'message'} ." ($filename:$line)\n";
};
@@
-283,9
+283,9
@@
sub InitLogging {
$p{message} =~ s/(?:\r*\n)+$//;
if ($p{level} eq 'debug') {
$p{message} =~ s/(?:\r*\n)+$//;
if ($p{level} eq 'debug') {
- return "
$p{message}
\n";
+ return "
[$$] $p{message} ($filename:$line)
\n";
} else {
} else {
- return "
$p{message} ($filename:$line)
\n";
+ return "
[$$] $p{message}
\n";
}
};
}
};