Skip to content

Commit 304ef13

Browse files
committed
Merge branch '4.4' into 5.0
* 4.4: Fix quotes in exception messages Fix quotes in exception messages Fix quotes in exception messages
2 parents e78ed3d + 34cb00a commit 304ef13

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

PropertyAccessor.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -849,7 +849,7 @@ private function getPropertyPath($propertyPath): PropertyPath
849849
public static function createCache(string $namespace, int $defaultLifetime, string $version, LoggerInterface $logger = null)
850850
{
851851
if (!class_exists('Symfony\Component\Cache\Adapter\ApcuAdapter')) {
852-
throw new \LogicException(sprintf('The Symfony Cache component must be installed to use %s().', __METHOD__));
852+
throw new \LogicException(sprintf('The Symfony Cache component must be installed to use "%s()".', __METHOD__));
853853
}
854854

855855
if (!ApcuAdapter::isSupported()) {

PropertyPath.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ public function getElements()
173173
public function getElement(int $index)
174174
{
175175
if (!isset($this->elements[$index])) {
176-
throw new OutOfBoundsException(sprintf('The index %s is not within the property path.', $index));
176+
throw new OutOfBoundsException(sprintf('The index "%s" is not within the property path.', $index));
177177
}
178178

179179
return $this->elements[$index];
@@ -185,7 +185,7 @@ public function getElement(int $index)
185185
public function isProperty(int $index)
186186
{
187187
if (!isset($this->isIndex[$index])) {
188-
throw new OutOfBoundsException(sprintf('The index %s is not within the property path.', $index));
188+
throw new OutOfBoundsException(sprintf('The index "%s" is not within the property path.', $index));
189189
}
190190

191191
return !$this->isIndex[$index];
@@ -197,7 +197,7 @@ public function isProperty(int $index)
197197
public function isIndex(int $index)
198198
{
199199
if (!isset($this->isIndex[$index])) {
200-
throw new OutOfBoundsException(sprintf('The index %s is not within the property path.', $index));
200+
throw new OutOfBoundsException(sprintf('The index "%s" is not within the property path.', $index));
201201
}
202202

203203
return $this->isIndex[$index];

PropertyPathBuilder.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ public function appendProperty(string $name)
9494
public function remove(int $offset, int $length = 1)
9595
{
9696
if (!isset($this->elements[$offset])) {
97-
throw new OutOfBoundsException(sprintf('The offset %s is not within the property path.', $offset));
97+
throw new OutOfBoundsException(sprintf('The offset "%s" is not within the property path.', $offset));
9898
}
9999

100100
$this->resize($offset, $length, 0);
@@ -149,7 +149,7 @@ public function replace(int $offset, int $length, $path, int $pathOffset = 0, in
149149
public function replaceByIndex(int $offset, string $name = null)
150150
{
151151
if (!isset($this->elements[$offset])) {
152-
throw new OutOfBoundsException(sprintf('The offset %s is not within the property path.', $offset));
152+
throw new OutOfBoundsException(sprintf('The offset "%s" is not within the property path.', $offset));
153153
}
154154

155155
if (null !== $name) {
@@ -170,7 +170,7 @@ public function replaceByIndex(int $offset, string $name = null)
170170
public function replaceByProperty(int $offset, string $name = null)
171171
{
172172
if (!isset($this->elements[$offset])) {
173-
throw new OutOfBoundsException(sprintf('The offset %s is not within the property path.', $offset));
173+
throw new OutOfBoundsException(sprintf('The offset "%s" is not within the property path.', $offset));
174174
}
175175

176176
if (null !== $name) {

0 commit comments

Comments
 (0)