Skip to content

Commit

Permalink
Fixed typo: Alais => Alias (#4856)
Browse files Browse the repository at this point in the history
  • Loading branch information
leoloso authored Dec 11, 2020
1 parent 1f7cd52 commit 7794d81
Show file tree
Hide file tree
Showing 7 changed files with 12 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ protected function resolveFqnTargetEntity(string $targetEntity, Node $node): str
return $namespacedTargetEntity;
}

$resolvedType = $this->objectTypeSpecifier->narrowToFullyQualifiedOrAlaisedObjectType(
$resolvedType = $this->objectTypeSpecifier->narrowToFullyQualifiedOrAliasedObjectType(
$node,
new ObjectType($targetEntity)
);
Expand Down
2 changes: 1 addition & 1 deletion packages/node-type-resolver/src/NodeTypeResolver.php
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ public function getStaticType(Node $node): Type
return $staticType;
}

return $this->objectTypeSpecifier->narrowToFullyQualifiedOrAlaisedObjectType($node, $staticType);
return $this->objectTypeSpecifier->narrowToFullyQualifiedOrAliasedObjectType($node, $staticType);
}

public function isNumberType(Node $node): bool
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ public function mapToPHPStanType(TypeNode $typeNode, Node $node, NameScope $name

$objectType = new ObjectType($typeNode->name);

return $this->objectTypeSpecifier->narrowToFullyQualifiedOrAlaisedObjectType($node, $objectType);
return $this->objectTypeSpecifier->narrowToFullyQualifiedOrAliasedObjectType($node, $objectType);
}

private function mapSelf(Node $node): Type
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ namespace Rector\CodingStyle\Tests\Rector\Namespace_\ImportFullyQualifiedNamesRe

use Symfony\Component\HttpFoundation\Request as HttpRequest;

final class KeepAlaised
final class KeepAliased
{
private const SUPPORTED_HTTP_METHODS = [
HttpRequest::METHOD_GET
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ private function processMethodArgument(string $class, string $method, EventInfo

private function resolveClassConstAliasMatch(ArrayItem $arrayItem, EventInfo $eventInfo): bool
{
foreach ($eventInfo->getOldClassConstAlaises() as $netteClassConst) {
foreach ($eventInfo->getOldClassConstAliases() as $netteClassConst) {
$classConstFetchNode = $arrayItem->key;
if ($classConstFetchNode === null) {
continue;
Expand Down
12 changes: 6 additions & 6 deletions rules/nette-to-symfony/src/ValueObject/EventInfo.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,21 +29,21 @@ final class EventInfo
/**
* @var string[]
*/
private $oldClassConstAlaises = [];
private $oldClassConstAliases = [];

/**
* @param string[] $oldStringAliases
* @param string[] $oldClassConstAlaises
* @param string[] $oldClassConstAliases
*/
public function __construct(
array $oldStringAliases,
array $oldClassConstAlaises,
array $oldClassConstAliases,
string $class,
string $constant,
string $eventClass
) {
$this->oldStringAliases = $oldStringAliases;
$this->oldClassConstAlaises = $oldClassConstAlaises;
$this->oldClassConstAliases = $oldClassConstAliases;
$this->class = $class;
$this->constant = $constant;
$this->eventClass = $eventClass;
Expand All @@ -60,9 +60,9 @@ public function getOldStringAliases(): array
/**
* @return string[]
*/
public function getOldClassConstAlaises(): array
public function getOldClassConstAliases(): array
{
return $this->oldClassConstAlaises;
return $this->oldClassConstAliases;
}

public function getClass(): string
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ final class ObjectTypeSpecifier
/**
* @return AliasedObjectType|FullyQualifiedObjectType|ObjectType|MixedType
*/
public function narrowToFullyQualifiedOrAlaisedObjectType(Node $node, ObjectType $objectType): Type
public function narrowToFullyQualifiedOrAliasedObjectType(Node $node, ObjectType $objectType): Type
{
/** @var Use_[]|null $uses */
$uses = $node->getAttribute(AttributeKey::USE_NODES);
Expand Down

0 comments on commit 7794d81

Please sign in to comment.