Merge "Add support for PHP7 random_bytes in favor of mcrypt_create_iv"
[lhc/web/wiklou.git] / includes / api / ApiQueryBlocks.php
index ef79efd..0040860 100644 (file)
@@ -36,8 +36,6 @@ class ApiQueryBlocks extends ApiQueryBase {
        }
 
        public function execute() {
-               global $wgContLang;
-
                $db = $this->getDB();
                $params = $this->extractRequestParams();
                $this->requireMaxOneParameter( $params, 'users', 'ip' );
@@ -204,7 +202,7 @@ class ApiQueryBlocks extends ApiQueryBase {
                                $block['timestamp'] = wfTimestamp( TS_ISO_8601, $row->ipb_timestamp );
                        }
                        if ( $fld_expiry ) {
-                               $block['expiry'] = $wgContLang->formatExpiry( $row->ipb_expiry, TS_ISO_8601 );
+                               $block['expiry'] = ApiResult::formatExpiry( $row->ipb_expiry );
                        }
                        if ( $fld_reason ) {
                                $block['reason'] = $row->ipb_reason;