Skip to content

Commit 1723cf5

Browse files
renamed variable to $componentDependsOnlyOnTheseNamespaces
1 parent 163a1b5 commit 1723cf5

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/RuleBuilders/Architecture/Architecture.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,14 @@ class Architecture implements Component, DefinedBy, Where, MayDependOnComponents
1717
/** @var array<string, string[]> */
1818
private $allowedDependencies;
1919
/** @var array<string, string[]> */
20-
private $allowedSpecificDependencies;
20+
private $componentDependsOnlyOnTheseNamespaces;
2121

2222
private function __construct()
2323
{
2424
$this->componentName = '';
2525
$this->componentSelectors = [];
2626
$this->allowedDependencies = [];
27-
$this->allowedSpecificDependencies = [];
27+
$this->componentDependsOnlyOnTheseNamespaces = [];
2828
}
2929

3030
public static function withComponents(): Component
@@ -62,7 +62,7 @@ public function shouldNotDependOnAnyComponent()
6262

6363
public function shouldOnlyDependOnComponents(string ...$componentNames)
6464
{
65-
$this->allowedSpecificDependencies[$this->componentName] = $componentNames;
65+
$this->componentDependsOnlyOnTheseNamespaces[$this->componentName] = $componentNames;
6666

6767
return $this;
6868
}
@@ -101,13 +101,13 @@ public function rules(): iterable
101101
}
102102
}
103103

104-
if (!isset($this->allowedSpecificDependencies[$name])) {
104+
if (!isset($this->componentDependsOnlyOnTheseNamespaces[$name])) {
105105
continue;
106106
}
107107

108108
$allowedDependencies = array_map(function (string $componentName): string {
109109
return $this->componentSelectors[$componentName];
110-
}, $this->allowedSpecificDependencies[$name]);
110+
}, $this->componentDependsOnlyOnTheseNamespaces[$name]);
111111

112112
yield Rule::allClasses()
113113
->that(new ResideInOneOfTheseNamespaces($selector))

0 commit comments

Comments
 (0)