Small (potential performance) improvement for logging framework.

This commit is contained in:
Seth Hall 2012-07-27 13:51:03 -04:00
parent 2a9993619f
commit 76520645bb

View file

@ -347,17 +347,17 @@ function __default_rotation_postprocessor(info: RotationInfo) : bool
}
function default_path_func(id: ID, path: string, rec: any) : string
{
local id_str = fmt("%s", id);
local parts = split1(id_str, /::/);
if ( |parts| == 2 )
{
# The suggested path value is a previous result of this function
# or a filter path explicitly set by the user, so continue using it.
if ( path != "" )
return path;
local id_str = fmt("%s", id);
local parts = split1(id_str, /::/);
if ( |parts| == 2 )
{
# Example: Notice::LOG -> "notice"
if ( parts[2] == "LOG" )
{