XW-2444: notice fix

This commit is contained in:
Mateusz Rybarski 2016-12-28 13:55:24 +01:00
parent c5c1a2c071
commit 34bea1521f

View file

@ -210,10 +210,8 @@ class PortableInfoboxParserTagController extends WikiaController {
$sourceParam = $colorName . '-source'; $sourceParam = $colorName . '-source';
$defaultParam = $colorName . '-default'; $defaultParam = $colorName . '-default';
$sourceParamValue = trim( $frame->getArgument( $params[ $sourceParam ] ) ); if ( isset( $params[ $sourceParam ] ) && !empty( $frame->getArgument( $params[ $sourceParam ] ) ) ) {
$color = trim( $frame->getArgument( $params[ $sourceParam ] ) );
if ( isset( $params[ $sourceParam ] ) && !empty( $sourceParamValue ) ) {
$color = $sourceParamValue;
} else if ( isset( $params[ $defaultParam ] ) ) { } else if ( isset( $params[ $defaultParam ] ) ) {
$color = trim( $params[ $defaultParam ] ); $color = trim( $params[ $defaultParam ] );
} else { } else {