Fix typos in comments (M)
Change-Id: I5ab88a01ba3e5ea2aae853bb6f06492fbc84ceb5
This commit is contained in:
parent
b4b2a62040
commit
b77dd0640c
15 changed files with 24 additions and 24 deletions
|
|
@ -1052,7 +1052,7 @@ class MediaWiki {
|
|||
in_array( http_response_code(), [ 200, 404 ], true ) &&
|
||||
// The queue of (post-send) deferred updates is non-empty
|
||||
DeferredUpdates::pendingUpdatesCount() &&
|
||||
// Any buffered output is not spread out accross multiple output buffers
|
||||
// Any buffered output is not spread out across multiple output buffers
|
||||
ob_get_level() <= 1 &&
|
||||
// It is not too late to set additional HTTP headers
|
||||
!headers_sent()
|
||||
|
|
|
|||
|
|
@ -1200,7 +1200,7 @@ class MediaWikiServices extends ServiceContainer {
|
|||
/**
|
||||
* Returns the main WAN cache, yielding EmptyBagOStuff if there is none
|
||||
*
|
||||
* The cache should relay any purge operations to all datacenterss
|
||||
* The cache should relay any purge operations to all datacenters
|
||||
*
|
||||
* @since 1.28
|
||||
* @return WANObjectCache
|
||||
|
|
|
|||
|
|
@ -496,7 +496,7 @@ class MergeHistory {
|
|||
// revisions are now tied to a different title and its content model
|
||||
// does not support redirects, so we cannot leave a new revision on it.
|
||||
// This deletion does not depend on userright but may still fails. If it
|
||||
// fails, it will be communicated in the status reponse.
|
||||
// fails, it will be communicated in the status response.
|
||||
$reason = wfMessage( 'mergehistory-source-deleted-reason' )->inContentLanguage()->plain();
|
||||
$deletionStatus = $newPage->doDeleteArticleReal( $reason, $user );
|
||||
// Notify callers that the source page has been deleted.
|
||||
|
|
|
|||
2
includes/cache/MessageCache.php
vendored
2
includes/cache/MessageCache.php
vendored
|
|
@ -617,7 +617,7 @@ class MessageCache implements LoggerAwareInterface {
|
|||
private function isLanguageLoaded( $lang ) {
|
||||
// It is important that this only returns true if the cache was fully
|
||||
// populated by load(), so that callers can assume all cache keys exist.
|
||||
// It is possible for $this->cache to be only patially populated through
|
||||
// It is possible for $this->cache to be only partially populated through
|
||||
// methods like MessageCache::replace(), which must not make this method
|
||||
// return true (T208897). And this method must cease to return true
|
||||
// if the language was evicted by MapCacheLRU (T230690).
|
||||
|
|
|
|||
|
|
@ -195,7 +195,7 @@ class MWException extends Exception {
|
|||
self::header( 'Content-Type: text/html; charset=utf-8' );
|
||||
echo "<!DOCTYPE html>\n" .
|
||||
'<html><head>' .
|
||||
// Mimick OutputPage::setPageTitle behaviour
|
||||
// Mimic OutputPage::setPageTitle behaviour
|
||||
'<title>' .
|
||||
htmlspecialchars( $this->msg( 'pagetitle', "$1 - $wgSitename", $this->getPageTitle() ) ) .
|
||||
'</title>' .
|
||||
|
|
|
|||
|
|
@ -135,7 +135,7 @@ class MWExceptionHandler {
|
|||
try {
|
||||
$services->getDBLoadBalancerFactory()->rollbackPrimaryChanges( __METHOD__ );
|
||||
} catch ( DBError $e2 ) {
|
||||
// If the DB is unreacheable, rollback() will throw an error
|
||||
// If the DB is unreachable, rollback() will throw an error
|
||||
// and the error report() method might need messages from the DB,
|
||||
// which would result in an exception loop. PHP may escalate such
|
||||
// errors to "Exception thrown without a stack frame" fatals, but
|
||||
|
|
@ -444,7 +444,7 @@ TXT;
|
|||
*
|
||||
* @since 1.26
|
||||
* @param array $trace Stacktrace
|
||||
* @return array Stacktrace with arugment values converted to data types
|
||||
* @return array Stacktrace with argument values converted to data types
|
||||
*/
|
||||
public static function redactTrace( array $trace ) {
|
||||
return array_map( static function ( $frame ) {
|
||||
|
|
@ -603,7 +603,7 @@ TXT;
|
|||
if ( $e instanceof ErrorException &&
|
||||
( error_reporting() & $e->getSeverity() ) === 0
|
||||
) {
|
||||
// Flag surpressed errors
|
||||
// Flag suppressed errors
|
||||
$data['suppressed'] = true;
|
||||
}
|
||||
|
||||
|
|
@ -750,7 +750,7 @@ TXT;
|
|||
);
|
||||
}
|
||||
|
||||
// Include all errors in the json log (surpressed errors will be flagged)
|
||||
// Include all errors in the json log (suppressed errors will be flagged)
|
||||
$json = self::jsonSerializeException( $e, false, FormatJson::ALL_OK, $catcher );
|
||||
if ( $json !== false ) {
|
||||
$logger = LoggerFactory::getInstance( "{$channel}-json" );
|
||||
|
|
@ -758,7 +758,7 @@ TXT;
|
|||
// and emits messages even if wikimedia/at-ease was used to suppress the
|
||||
// error. To avoid clobbering Logstash dashboards with these, make sure
|
||||
// those have their level casted to DEBUG so that they are excluded by
|
||||
// level-based filteres automatically instead of requiring a dedicated filter
|
||||
// level-based filters automatically instead of requiring a dedicated filter
|
||||
// for this channel. To be improved: T193472.
|
||||
$unfilteredLevel = $suppressed ? LogLevel::DEBUG : $level;
|
||||
$logger->log( $unfilteredLevel, $json, [ 'private' => true ] );
|
||||
|
|
|
|||
|
|
@ -161,7 +161,7 @@ class MWExceptionRenderer {
|
|||
$pageTitle = self::msg( 'internalerror', 'Internal error' );
|
||||
echo "<!DOCTYPE html>\n" .
|
||||
'<html><head>' .
|
||||
// Mimick OutputPage::setPageTitle behaviour
|
||||
// Mimic OutputPage::setPageTitle behaviour
|
||||
'<title>' .
|
||||
htmlspecialchars( self::msg( 'pagetitle', "$1 - $wgSitename", $pageTitle ) ) .
|
||||
'</title>' .
|
||||
|
|
|
|||
|
|
@ -538,7 +538,7 @@ class MysqlInstaller extends DatabaseInstaller {
|
|||
$grantableNames[] = $fullName;
|
||||
break;
|
||||
} else {
|
||||
// If we couldn't create for some bizzare reason and the
|
||||
// If we couldn't create for some bizarre reason and the
|
||||
// user probably doesn't exist, skip the grant
|
||||
$this->db->rollback( __METHOD__ );
|
||||
$status->warning( 'config-install-user-create-failed', $dbUser, $dqe->getMessage() );
|
||||
|
|
|
|||
|
|
@ -1280,7 +1280,7 @@ class Message implements MessageSpecifier, Serializable {
|
|||
// A temporary marker for $1 parameters that is only valid
|
||||
// in non-attribute contexts. However if the entire message is escaped
|
||||
// then we don't want to use it because it will be mangled in all contexts
|
||||
// and its unnessary as ->escaped() messages aren't html.
|
||||
// and its unnecessary as ->escaped() messages aren't html.
|
||||
$marker = $format === self::FORMAT_ESCAPED ? '$' : '$\'"';
|
||||
$replacementKeys = [];
|
||||
foreach ( $this->parameters as $n => $param ) {
|
||||
|
|
|
|||
|
|
@ -916,7 +916,7 @@ class MimeAnalyzer implements LoggerAwareInterface {
|
|||
|
||||
/**
|
||||
* Internal MIME type detection. Detection is done using the fileinfo
|
||||
* extension if it is available. It can be overriden by callback, which could
|
||||
* extension if it is available. It can be overridden by callback, which could
|
||||
* use an external program, for example. If detection fails and $ext is not false,
|
||||
* the MIME type is guessed from the file extension, using getMimeTypeFromExtensionOrNull.
|
||||
*
|
||||
|
|
|
|||
|
|
@ -256,7 +256,7 @@ abstract class MediumSpecificBagOStuff extends BagOStuff {
|
|||
* The callback function returns the new value given the current value
|
||||
* (which will be false if not present), and takes the arguments:
|
||||
* (this BagOStuff, cache key, current value, TTL).
|
||||
* The TTL parameter is reference set to $exptime. It can be overriden in the callback.
|
||||
* The TTL parameter is reference set to $exptime. It can be overridden in the callback.
|
||||
* Nothing is stored nor deleted if the callback returns false.
|
||||
*
|
||||
* @param string $key
|
||||
|
|
|
|||
|
|
@ -82,7 +82,7 @@ class MultiWriteBagOStuff extends BagOStuff {
|
|||
} else {
|
||||
if ( !isset( $cacheInfo['args'] ) ) {
|
||||
// B/C for when $cacheInfo was for ObjectCache::newFromParams().
|
||||
// Callers intenting this to be for ObjectFactory::getObjectFromSpec
|
||||
// Callers intending this to be for ObjectFactory::getObjectFromSpec
|
||||
// should have set "args" per the docs above. Doings so avoids extra
|
||||
// (likely harmless) params (factory/class/calls) ending up in "args".
|
||||
$cacheInfo['args'] = [ $cacheInfo ];
|
||||
|
|
|
|||
|
|
@ -610,7 +610,7 @@ class MemcachedClient {
|
|||
* @param int $exp (optional) Expiration time. This can be a number of seconds
|
||||
* to cache for (up to 30 days inclusive). Any timespans of 30 days + 1 second or
|
||||
* longer must be the timestamp of the time at which the mapping should expire. It
|
||||
* is safe to use timestamps in all cases, regardless of exipration
|
||||
* is safe to use timestamps in all cases, regardless of expiration
|
||||
* eg: strtotime("+3 hour")
|
||||
*
|
||||
* @return bool
|
||||
|
|
@ -666,7 +666,7 @@ class MemcachedClient {
|
|||
* @param int $exp (optional) Expiration time. This can be a number of seconds
|
||||
* to cache for (up to 30 days inclusive). Any timespans of 30 days + 1 second or
|
||||
* longer must be the timestamp of the time at which the mapping should expire. It
|
||||
* is safe to use timestamps in all cases, regardless of exipration
|
||||
* is safe to use timestamps in all cases, regardless of expiration
|
||||
* eg: strtotime("+3 hour")
|
||||
*
|
||||
* @return bool True on success
|
||||
|
|
@ -688,7 +688,7 @@ class MemcachedClient {
|
|||
* @param int $exp (optional) Expiration time. This can be a number of seconds
|
||||
* to cache for (up to 30 days inclusive). Any timespans of 30 days + 1 second or
|
||||
* longer must be the timestamp of the time at which the mapping should expire. It
|
||||
* is safe to use timestamps in all cases, regardless of exipration
|
||||
* is safe to use timestamps in all cases, regardless of expiration
|
||||
* eg: strtotime("+3 hour")
|
||||
*
|
||||
* @return bool True on success
|
||||
|
|
@ -911,7 +911,7 @@ class MemcachedClient {
|
|||
// {{{ _incrdecr()
|
||||
|
||||
/**
|
||||
* Perform increment/decriment on $key
|
||||
* Perform increment/decrement on $key
|
||||
*
|
||||
* @param string $cmd Command to perform
|
||||
* @param string|array $key Key to perform it on
|
||||
|
|
@ -1046,7 +1046,7 @@ class MemcachedClient {
|
|||
* @param int $exp (optional) Expiration time. This can be a number of seconds
|
||||
* to cache for (up to 30 days inclusive). Any timespans of 30 days + 1 second or
|
||||
* longer must be the timestamp of the time at which the mapping should expire. It
|
||||
* is safe to use timestamps in all cases, regardless of exipration
|
||||
* is safe to use timestamps in all cases, regardless of expiration
|
||||
* eg: strtotime("+3 hour")
|
||||
* @param float $casToken [optional]
|
||||
*
|
||||
|
|
|
|||
|
|
@ -816,7 +816,7 @@ abstract class MediaHandler {
|
|||
}
|
||||
|
||||
/**
|
||||
* Long description. Shown under image on image description page surounded by ().
|
||||
* Long description. Shown under image on image description page surrounded by ().
|
||||
*
|
||||
* @stable to override
|
||||
*
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
<?php
|
||||
/**
|
||||
* Extract-and-Expand Key Derivation Function (HKDF). A cryptographicly
|
||||
* Extract-and-Expand Key Derivation Function (HKDF). A cryptographically
|
||||
* secure key expansion function based on RFC 5869.
|
||||
*
|
||||
* This relies on the secrecy of $wgSecretKey (by default), or $wgHKDFSecret.
|
||||
|
|
@ -46,7 +46,7 @@ class MWCryptHKDF {
|
|||
* RFC5869 defines HKDF in 2 steps, extraction and expansion.
|
||||
* From http://eprint.iacr.org/2010/264.pdf:
|
||||
*
|
||||
* The scheme HKDF is specifed as:
|
||||
* The scheme HKDF is specified as:
|
||||
* HKDF(XTS, SKM, CTXinfo, L) = K(1) || K(2) || ... || K(t)
|
||||
* where the values K(i) are defined as follows:
|
||||
* PRK = HMAC(XTS, SKM)
|
||||
|
|
|
|||
Loading…
Reference in a new issue