Add check for empty tested ratings to the conditions upon which we will skip trying to color
using the tested rating. Remove two unused variables.
This commit is contained in:
@@ -1112,20 +1112,19 @@ class version {
|
|||||||
$oTableRowHighlight = null;
|
$oTableRowHighlight = null;
|
||||||
|
|
||||||
// if we have a valid tested rating
|
// if we have a valid tested rating
|
||||||
if($oVersion->sTestedRating && $oVersion->sTestedRating != "/")
|
if($oVersion->sTestedRating && ($oVersion->sTestedRating != "/") &&
|
||||||
|
($oVersion->sTestedRating != " "))
|
||||||
{
|
{
|
||||||
$sRatingColor = "class=\"$oVersion->sTestedRating\"";
|
|
||||||
$sClass = $oVersion->sTestedRating;
|
$sClass = $oVersion->sTestedRating;
|
||||||
|
|
||||||
$oInactiveColor = new Color();
|
$oInactiveColor = new Color();
|
||||||
$oInactiveColor->setColorByName($oVersion->sTestedRating);
|
$oInactiveColor->SetColorByName($oVersion->sTestedRating);
|
||||||
|
|
||||||
$oHighlightColor = GetHighlightColorFromInactiveColor($oInactiveColor);
|
$oHighlightColor = GetHighlightColorFromInactiveColor($oInactiveColor);
|
||||||
|
|
||||||
$oTableRowHighlight = new TableRowHighlight($oHighlightColor, $oInactiveColor);
|
$oTableRowHighlight = new TableRowHighlight($oHighlightColor, $oInactiveColor);
|
||||||
} else
|
} else
|
||||||
{
|
{
|
||||||
$sRatingColor = "class=\"$bgcolor\"";
|
|
||||||
$sClass = $bgcolor;
|
$sClass = $bgcolor;
|
||||||
|
|
||||||
$oTableRowHighlight = GetStandardRowHighlight($c);
|
$oTableRowHighlight = GetStandardRowHighlight($c);
|
||||||
|
|||||||
Reference in New Issue
Block a user