[rt-users] Cheap performance improvement

William George william.george at vonage.com
Wed Jan 21 10:39:47 EST 2004


Here's a real cheap performance improvement: default all Requestor searches to "=" instead of "LIKE". The code is in html/Elements/SelectMenu and looks like it never worked the way it was intended.

I replaced the following flawed code:

if ($Default && $Default !~ /true/i) {
        $FalseDefault = "SELECTED";
}
elsif ($Default && $Default !~ /false/i) {
        $TrueDefault = "SELECTED";
}
elsif ($Default && $Default !~ /notlike/i) {
        $NotLikeDefault = "SELECTED";
}
else {
        $LikeDefault = "SELECTED";
}

With:

$TrueDefault = "SELECTED";

Bill George
Resident RT Hacker
Vonage.com

295,000 Tickets and counting!






More information about the rt-users mailing list