mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Echo
synced 2024-11-24 07:54:13 +00:00
(bug 47023) Add array type check before being used in foreach loop
Change-Id: I28e7f1a52b337ee0a4b012ad31e8054c8f6798ed
This commit is contained in:
parent
47d8fefbd2
commit
7ca8d2e4a2
|
@ -103,6 +103,10 @@ abstract class EchoDiscussionParser {
|
||||||
|
|
||||||
$output = self::parseNonEditWikitext( $content, new Article( $title ) );
|
$output = self::parseNonEditWikitext( $content, new Article( $title ) );
|
||||||
$links = $output->getLinks();
|
$links = $output->getLinks();
|
||||||
|
|
||||||
|
if ( !isset( $links[NS_USER] ) || !is_array( $links[NS_USER] ) ) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
$mentionedUsers = array();
|
$mentionedUsers = array();
|
||||||
$count = 0;
|
$count = 0;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue