jenkins-bot has submitted this change and it was merged.

Change subject: Fix PHP warning that breaks author output in JsonFFS
......................................................................


Fix PHP warning that breaks author output in JsonFFS

Bug: 58738
Change-Id: Ifc45dddcec3094a8f061e407fb9f29fa9aab5968
---
M ffs/JsonFFS.php
1 file changed, 4 insertions(+), 1 deletion(-)

Approvals:
  Siebrand: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/ffs/JsonFFS.php b/ffs/JsonFFS.php
index dfe86c5..359abcf 100644
--- a/ffs/JsonFFS.php
+++ b/ffs/JsonFFS.php
@@ -73,7 +73,10 @@
                $authors = $collection->getAuthors();
                $authors = $this->filterAuthors( $authors, $collection->code );
 
-               $authors = array_unique( array_merge( $template['AUTHORS'], 
$authors ) );
+               if ( isset( $template['AUTHORS'] ) ) {
+                       $authors = array_unique( array_merge( 
$template['AUTHORS'], $authors ) );
+               }
+
                if ( $authors !== array() ) {
                        $messages['@metadata']['authors'] = array_values( 
$authors );
                }

-- 
To view, visit https://gerrit.wikimedia.org/r/103116
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ifc45dddcec3094a8f061e407fb9f29fa9aab5968
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/Translate
Gerrit-Branch: master
Gerrit-Owner: Nikerabbit <niklas.laxst...@gmail.com>
Gerrit-Reviewer: Siebrand <siebr...@wikimedia.org>
Gerrit-Reviewer: jenkins-bot

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to