X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2FMessage.php;h=be6b0aff0fd702696023e84b7c8f269aa5a65a22;hb=64b83bdb3afd0ee4f8fc1893a865409c198e601e;hp=9c0ab1ce28629a21edcf4ecdfcde6514a591281e;hpb=81518f218a4610db96670e1bedff874c65dfec81;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/Message.php b/includes/Message.php index 9c0ab1ce28..be6b0aff0f 100644 --- a/includes/Message.php +++ b/includes/Message.php @@ -419,7 +419,7 @@ class Message implements MessageSpecifier, Serializable { } if ( $value instanceof Message ) { // Message, RawMessage, ApiMessage, etc - $message = clone( $value ); + $message = clone $value; } elseif ( $value instanceof MessageSpecifier ) { $message = new Message( $value ); } elseif ( is_string( $value ) ) { @@ -1054,9 +1054,9 @@ class Message implements MessageSpecifier, Serializable { /** * @since 1.22 * - * @param number $period + * @param int $period * - * @return number[] Array with a single "period" key. + * @return int[] Array with a single "period" key. */ public static function timeperiodParam( $period ) { return [ 'period' => $period ]; @@ -1305,8 +1305,9 @@ class Message implements MessageSpecifier, Serializable { */ protected function formatListParam( array $params, $listType, $format ) { if ( !isset( self::$listTypeMap[$listType] ) ) { - $warning = 'Invalid list type for message "' . $this->getKey() . '": ' . - htmlspecialchars( serialize( $param ) ); + $warning = 'Invalid list type for message "' . $this->getKey() . '": ' + . htmlspecialchars( $listType ) + . ' (params are ' . htmlspecialchars( serialize( $params ) ) . ')'; trigger_error( $warning, E_USER_WARNING ); $e = new Exception; wfDebugLog( 'Bug58676', $warning . "\n" . $e->getTraceAsString() );