mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/ParserFunctions
synced 2024-11-15 20:09:43 +00:00
Apply live hack from Wikimedia code base: throw exception on invalid frames in ifeq
This commit is contained in:
parent
b7b5f0790e
commit
e9620129be
|
@ -126,6 +126,9 @@ class ExtParserFunctions {
|
|||
}
|
||||
|
||||
function ifeqObj( &$parser, $frame, $args ) {
|
||||
if ( !is_object( $frame ) ) {
|
||||
throw new MWException( __METHOD__.': invalid frame' );
|
||||
}
|
||||
$left = isset( $args[0] ) ? trim( $frame->expand( $args[0] ) ) : '';
|
||||
$right = isset( $args[1] ) ? trim( $frame->expand( $args[1] ) ) : '';
|
||||
if ( $left == $right ) {
|
||||
|
|
Loading…
Reference in a new issue