Merge "Upgrade to newer phan"
[lhc/web/wiklou.git] / includes / api / ApiParse.php
index fc730e3..5e4639d 100644 (file)
@@ -632,8 +632,8 @@ class ApiParse extends ApiBase {
         */
        private function formatSummary( $title, $params ) {
                global $wgParser;
-               $summary = !is_null( $params['summary'] ) ? $params['summary'] : '';
-               $sectionTitle = !is_null( $params['sectiontitle'] ) ? $params['sectiontitle'] : '';
+               $summary = $params['summary'] ?? '';
+               $sectionTitle = $params['sectiontitle'] ?? '';
 
                if ( $this->section === 'new' && ( $sectionTitle === '' || $summary === '' ) ) {
                        if ( $sectionTitle !== '' ) {