Skip to content

Commit

Permalink
additional typo fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
bkdotcom committed Apr 1, 2024
1 parent ac4ff7f commit a30f7b8
Show file tree
Hide file tree
Showing 42 changed files with 88 additions and 88 deletions.
2 changes: 1 addition & 1 deletion src/Backtrace/Backtrace.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ class Backtrace

/**
* Add a new namespace or classname to be used to determine when to
* stop iterrating over the backtrace when determining calling info
* stop iterating over the backtrace when determining calling info
*
* @param array|string $classes classname(s)
* @param int $level "priority". 0 = will never skip
Expand Down
2 changes: 1 addition & 1 deletion src/Backtrace/Normalizer.php
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ public static function normalize($backtrace)
$frame = self::normalizeFrameFunction($frame);
if (\in_array($frame['function'], array('call_user_func', 'call_user_func_array'), true)) {
// don't include this frame
// backtrace only includes when used within namespace and not fully-quallified
// backtrace only includes when used within namespace and not fully-qualified
// \call_user_func(); // not in trace... same as calling func directly
continue;
}
Expand Down
2 changes: 1 addition & 1 deletion src/Backtrace/SkipInternal.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class SkipInternal

/**
* Add a new namespace or classname to be used to determine when to
* stop iterrating over the backtrace when determining calling info
* stop iterating over the backtrace when determining calling info
*
* @param array|string $classes classname(s)
* @param int $level "priority"
Expand Down
2 changes: 1 addition & 1 deletion src/Container/Container.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ class Container implements \ArrayAccess
{
/** @var array */
private $cfg = array(
'allowOverride' => false, // whether can update alreay built service
'allowOverride' => false, // whether can update already built service
'onInvoke' => null, // callable
);

Expand Down
2 changes: 1 addition & 1 deletion src/CurlHttpMessage/Client.php
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ public function trace($uri, array $headers = array()) // @phpcs:ignore Generic.C
*/
public function handle(RequestInterface $request, array $options = array()) // @phpcs:ignore Generic.CodeAnalysis.UselessOverridingMethod
{
$options['isAsyncronous'] = false;
$options['isAsynchronous'] = false;
$promise = parent::handle($request, $options);
return $promise->wait();
}
Expand Down
4 changes: 2 additions & 2 deletions src/CurlHttpMessage/ClientAsync.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
use Psr\Http\Message\RequestInterface;

/**
* Lightweight PSR-7 (HttpMessage) based cURL asyncronous client
* Lightweight PSR-7 (HttpMessage) based cURL asynchronous client
*/
class ClientAsync extends AbstractClient
{
Expand All @@ -18,7 +18,7 @@ class ClientAsync extends AbstractClient
*/
public function handle(RequestInterface $request, array $options = array())
{
$options['isAsyncronous'] = true;
$options['isAsynchronous'] = true;
return parent::handle($request, $options);
}

Expand Down
2 changes: 1 addition & 1 deletion src/CurlHttpMessage/CurlReqRes.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class CurlReqRes
private $options = array(
'curl' => array(),
'delay' => null,
'isAsyncronous' => false,
'isAsynchronous' => false,
'maxRedirect' => 5,
'noEarlierThan' => null,
);
Expand Down
2 changes: 1 addition & 1 deletion src/CurlHttpMessage/Factory.php
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ public static function buildStack(callable $handler = null)
$asyncHandler = new CurlMulti();
$handler = static function (CurlReqRes $curlReqRes) use ($syncHandler, $asyncHandler) {
$options = $curlReqRes->getOptions();
return $options['isAsyncronous']
return $options['isAsynchronous']
? $asyncHandler($curlReqRes)
: $syncHandler($curlReqRes);
};
Expand Down
4 changes: 2 additions & 2 deletions src/CurlHttpMessage/Handler/CurlMulti.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class CurlMulti extends Curl
/** @var array options */
protected $options = array();

/** @var CurlReqRes[] Requests currenting being executed by curl indexed by (int) curlHandle */
/** @var CurlReqRes[] Requests currently being executed by curl indexed by (int) curlHandle */
private $processing = array();

/** @var CurlReqRes[] Request Queue indexed by CurlReqRes hash*/
Expand Down Expand Up @@ -134,7 +134,7 @@ private function getCurlHandle()
}

/**
* Return delay (in milli seconds)
* Return delay (in milliseconds)
*
* @return int
*/
Expand Down
2 changes: 1 addition & 1 deletion src/CurlHttpMessage/HandlerStack.php
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ private function assertName($name)
return $callableAndName[1] === $name;
});
if (\count($found) > 0) {
throw new RuntimeException('Middlware already in stack: ' . $name);
throw new RuntimeException('Middleware already in stack: ' . $name);
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/CurlHttpMessage/Middleware/FollowLocation.php
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ protected function handleCrossOrigin(CurlReqRes $curlReqRes, RequestInterface $r
* Handle 301 and 302 response codes
*
* According to the HTTP specs,
* a 303 redirection should be followed usingthe GET method.
* a 303 redirection should be followed using the GET method.
* 301 and 302 must not.
*
* @param CurlReqRes $curlReqRes CurlReqRes instance
Expand Down
8 changes: 4 additions & 4 deletions src/Debug/AbstractDebug.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
use ReflectionMethod;

/**
* Handle underlying Debug bootstraping and config
* Handle underlying Debug bootstrapping and config
*
* @psalm-consistent-constructor
*/
Expand Down Expand Up @@ -100,7 +100,7 @@ public function __call($methodName, $args)
public static function __callStatic($methodName, $args)
{
// prior to v3.1 it was required to have underscore prefix to disambiguate from instance method
// as of v3.1, all methodss provided via plugin
// as of v3.1, all methods provided via plugin
$methodName = \ltrim($methodName, '_');
if (!self::$instance && $methodName === 'setCfg') {
/*
Expand Down Expand Up @@ -317,7 +317,7 @@ private function bootstrap($cfg)
}

/**
* Get config values needed for bootstraping
* Get config values needed for bootstrapping
*
* @param array $cfg Config passed to constructor
*
Expand Down Expand Up @@ -351,7 +351,7 @@ private function bootstrapConfig(&$cfg)
}

/**
* Initialize dependancy containers
* Initialize dependency containers
*
* @param array $cfg Initial cfg values
*
Expand Down
4 changes: 2 additions & 2 deletions src/Debug/Abstraction/AbstractObject.php
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ public static function buildObjValues(array $values = array())
}

/**
* Populate rows or columns (traverseValues) if we're outputing as a table
* Populate rows or columns (traverseValues) if we're outputting as a table
*
* @param ObjectAbstraction $abs Abstraction instance
*
Expand Down Expand Up @@ -307,7 +307,7 @@ private function doAbstraction(ObjectAbstraction $abs)
$this->methods->addInstance($abs); // method static variables
$this->properties->addInstance($abs);
/*
Debug::EVENT_OBJ_ABSTRACT_END subscriber has free reign to modify abtraction values
Debug::EVENT_OBJ_ABSTRACT_END subscriber has free reign to modify abstraction values
*/
$this->debug->publishBubbleEvent(Debug::EVENT_OBJ_ABSTRACT_END, $abs, $this->debug);
}
Expand Down
2 changes: 1 addition & 1 deletion src/Debug/Abstraction/Abstracter.php
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,7 @@ protected function postSetCfg($cfg = array(), $prev = array())
}

/**
* Pass relevent config updates to AbstractObject & AbstractString
* Pass relevant config updates to AbstractObject & AbstractString
*
* @param array $cfg Updated config values
*
Expand Down
2 changes: 1 addition & 1 deletion src/Debug/Abstraction/Abstraction.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class Abstraction extends Event
* Constructor
*
* @param string $type value type (one of the Abstracter TYPE_XXX constants)
* @param array $values abtraction values
* @param array $values Abstraction values
*/
public function __construct($type, $values = array())
{
Expand Down
4 changes: 2 additions & 2 deletions src/Debug/Abstraction/Object/Abstraction.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ class Abstraction extends BaseAbstraction
* Constructor
*
* @param ValueStore $inherited Inherited values
* @param array $values Abtraction values
* @param array $values Abstraction values
*/
public function __construct(ValueStore $inherited, $values = array())
{
Expand Down Expand Up @@ -266,7 +266,7 @@ protected function sortData(array $array)
? $info['visibility']
: '?';
if (\is_array($vis)) {
// Sort the visiblity so we use the most significant vis
// Sort the visibility so we use the most significant vis
ArrayUtil::sortWithOrder($vis, $sortVisOrder);
$vis = $vis[0];
}
Expand Down
2 changes: 1 addition & 1 deletion src/Debug/Abstraction/Object/Definition.php
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,7 @@ protected function getInterfaces(ReflectionClass $reflector)
*
* @param array $values values already collected
*
* @return Absttraction
* @return Abstraction
*/
protected function getInitValues(array $values)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Debug/Abstraction/Object/PropertiesPhpDoc.php
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ private function addViaPhpDocInherit(Abstraction $abs)
}

/**
* Iterate over PhpDoc's magic properties & add to abstrction
* Iterate over PhpDoc's magic properties & add to abstraction
*
* @param Abstraction $abs Object Abstraction instance
* @param string|null $declaredLast Where the magic properties were found
Expand Down
16 changes: 8 additions & 8 deletions src/Debug/Collector/AbstractAsyncMiddleware.php
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ public function __invoke(callable $nextHandler)
}

/**
* Subscribe to logEntry output... conditionaly output response group
* Subscribe to logEntry output... conditionally output response group
*
* @param LogEntry $logEntry LogEntry instance
*
Expand All @@ -105,7 +105,7 @@ public function onOutputLogEntry(LogEntry $logEntry)
/**
* Called when redirect encountered
* but only if this middleware is added to the bottom of the stack (unshift)
* and only for syncronous request
* and only for synchronous request
*
* @param RequestInterface $request Request
* @param ResponseInterface $response Response
Expand All @@ -132,7 +132,7 @@ public function onRedirect(RequestInterface $request, ResponseInterface $respons
public function onFulfilled(ResponseInterface $response, array $requestInfo)
{
$meta = $this->debug->meta();
if ($requestInfo['isAsyncronous']) {
if ($requestInfo['isAsynchronous']) {
$meta = $this->debug->meta(array(
'asyncResponseGroup' => true,
'middlewareId' => \spl_object_hash($this),
Expand All @@ -149,7 +149,7 @@ public function onFulfilled(ResponseInterface $response, array $requestInfo)
}

/**
* Start a new group for asyncronous response
* Start a new group for asynchronous response
*
* @param RequestInterface $request RequestInterface
* @param ResponseInterface|null $response ResponseInterface (if available)
Expand Down Expand Up @@ -245,12 +245,12 @@ protected function logRequest(RequestInterface $request, array $requestInfo)
'redact' => true,
))
);
if ($requestInfo['isAsyncronous']) {
$this->debug->info('asyncronous', $this->debug->meta('icon', $this->cfg['iconAsync']));
if ($requestInfo['isAsynchronous']) {
$this->debug->info('asynchronous', $this->debug->meta('icon', $this->cfg['iconAsync']));
}
$this->debug->log('request headers', $this->buildHeadersString($request));
$this->logRequestBody($request);
if ($requestInfo['isAsyncronous']) {
if ($requestInfo['isAsynchronous']) {
$this->debug->groupEnd();
}
}
Expand Down Expand Up @@ -288,7 +288,7 @@ protected function logRequestBody(RequestInterface $request)
protected function logResponse(ResponseInterface $response = null, array $requestInfo = array(), Exception $rejectReason = null)
{
$duration = $this->debug->timeEnd($this->cfg['label'] . ':' . $requestInfo['requestId'], false);
$metaAppend = $requestInfo['isAsyncronous'] && $this->cfg['asyncResponseWithRequest']
$metaAppend = $requestInfo['isAsynchronous'] && $this->cfg['asyncResponseWithRequest']
? $this->debug->meta('appendGroup', $this->cfg['idPrefix'] . $requestInfo['requestId'])
: $this->debug->meta();
if ($rejectReason) {
Expand Down
8 changes: 4 additions & 4 deletions src/Debug/Collector/CurlHttpMessageMiddleware.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,12 @@ public function onRequest(CurlReqRes $curlReqRes)
$request = $curlReqRes->getRequest();
$options = $curlReqRes->getOptions();
$requestInfo = array(
'isAsyncronous' => $options['isAsyncronous'],
'isAsynchronous' => $options['isAsynchronous'],
'request' => $request,
'requestId' => \spl_object_hash($request),
);
$this->onRedirectOrig = $options['onRedirect'];
if ($requestInfo['isAsyncronous'] === false) {
if ($requestInfo['isAsynchronous'] === false) {
$curlReqRes->setOption('onRedirect', array($this, 'onRedirect'));
}
$this->logRequest($request, $requestInfo);
Expand All @@ -71,7 +71,7 @@ public function onRejected(RequestException $reason, array $requestInfo)
{
$meta = $this->debug->meta();
$response = $reason->getResponse();
if ($requestInfo['isAsyncronous']) {
if ($requestInfo['isAsynchronous']) {
$meta = $this->debug->meta(array(
'asyncResponseGroup' => true,
'middlewareId' => \spl_object_hash($this),
Expand All @@ -89,7 +89,7 @@ public function onRejected(RequestException $reason, array $requestInfo)
}

/**
* call nexthandler and register our fullfill and reject callbacks
* call nextHandler and register our fulfill and reject callbacks
*
* @param CurlReqRes $curlReqRes CurlReqRes instance
* @param array $requestInfo Request info
Expand Down
8 changes: 4 additions & 4 deletions src/Debug/Collector/GuzzleMiddleware.php
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public function __construct($cfg = array(), Debug $debug = null)
public function onRequest(RequestInterface $request, array $options)
{
$requestInfo = array(
'isAsyncronous' => empty($options[RequestOptions::SYNCHRONOUS]),
'isAsynchronous' => empty($options[RequestOptions::SYNCHRONOUS]),
'request' => $request,
'requestId' => \spl_object_hash($request),
);
Expand All @@ -60,7 +60,7 @@ public function onRequest(RequestInterface $request, array $options)
$this->onRedirectOrig = isset($options['allow_redirects']['on_redirect'])
? $options['allow_redirects']['on_redirect']
: null;
if ($requestInfo['isAsyncronous'] === false) {
if ($requestInfo['isAsynchronous'] === false) {
$options['allow_redirects']['on_redirect'] = array($this, 'onRedirect');
}
}
Expand All @@ -82,7 +82,7 @@ public function onRejected(GuzzleException $reason, array $requestInfo)
$response = $reason instanceof RequestException
? $reason->getResponse()
: null;
if ($requestInfo['isAsyncronous']) {
if ($requestInfo['isAsynchronous']) {
$meta = $this->debug->meta(array(
'asyncResponseGroup' => true,
'middlewareId' => \spl_object_hash($this),
Expand All @@ -102,7 +102,7 @@ public function onRejected(GuzzleException $reason, array $requestInfo)
}

/**
* call nexthandler and register our fullfill and reject callbacks
* call nextHandler and register our fulfill and reject callbacks
*
* @param RequestInterface $request Psr7 RequestInterface
* @param array $options Guzzle request options
Expand Down
2 changes: 1 addition & 1 deletion src/Debug/Collector/PhpCurlClass.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
/**
* Extend php-curl-class to log each request
*
* Decorator (that extends Curl) would be prefered.. however unable to handle Curl's public properties
* Decorator (that extends Curl) would be preferred.. however unable to handle Curl's public properties
*
* @see https://github.com/php-curl-class/php-curl-class
*/
Expand Down
2 changes: 1 addition & 1 deletion src/Debug/Collector/SimpleCache/CallInfo.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ class CallInfo extends AbstractComponent

/**
* @param string $method method called
* @param mixed $keyOrKeys affeccted key or keys
* @param mixed $keyOrKeys affected key or keys
*/
public function __construct($method, $keyOrKeys = null)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Debug/Collector/SoapClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ private function debugGetXmlResponse(&$faultInfo)
}

/**
* Check if __call is in backtracew
* Check if __call is in backtrace
*
* @return bool
*/
Expand Down
2 changes: 1 addition & 1 deletion src/Debug/Collector/StatementInfo.php
Original file line number Diff line number Diff line change
Expand Up @@ -441,7 +441,7 @@ function () {
}

/**
* Process query analysys test and log result if test fails
* Process query analysis test and log result if test fails
*
* @param array|closure $test query test
*
Expand Down
Loading

0 comments on commit a30f7b8

Please sign in to comment.