Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 040bf90

Browse filesBrowse files
committed
minor #36085 Add missing dots at the end of exception messages (fabpot)
This PR was merged into the 5.0 branch. Discussion ---------- Add missing dots at the end of exception messages | Q | A | ------------- | --- | Branch? | 5.0 | Bug fix? | no | New feature? | no <!-- please update src/**/CHANGELOG.md files --> | Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files --> | Tickets | n/a <!-- prefix each issue number with "Fix #", if any --> | License | MIT | Doc PR | n/a Commits ------- 81cf967 Add missing dots at the end of exception messages
2 parents 20a1988 + 81cf967 commit 040bf90
Copy full SHA for 040bf90

File tree

6 files changed

+12
-12
lines changed
Filter options

6 files changed

+12
-12
lines changed

‎src/Symfony/Component/BrowserKit/AbstractBrowser.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/BrowserKit/AbstractBrowser.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -451,7 +451,7 @@ protected function doRequestInProcess($request)
451451
}
452452

453453
if (!$process->isSuccessful() || !preg_match('/^O\:\d+\:/', $process->getOutput())) {
454-
throw new \RuntimeException(sprintf('OUTPUT: %s ERROR OUTPUT: %s', $process->getOutput(), $process->getErrorOutput()));
454+
throw new \RuntimeException(sprintf('OUTPUT: %s ERROR OUTPUT: %s.', $process->getOutput(), $process->getErrorOutput()));
455455
}
456456

457457
return unserialize($process->getOutput());

‎src/Symfony/Component/Cache/Adapter/ApcuAdapter.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Cache/Adapter/ApcuAdapter.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ class ApcuAdapter extends AbstractAdapter
2525
public function __construct(string $namespace = '', int $defaultLifetime = 0, string $version = null)
2626
{
2727
if (!static::isSupported()) {
28-
throw new CacheException('APCu is not enabled');
28+
throw new CacheException('APCu is not enabled.');
2929
}
3030
if ('cli' === \PHP_SAPI) {
3131
ini_set('apc.use_request_time', 0);

‎src/Symfony/Component/Cache/Adapter/MemcachedAdapter.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Cache/Adapter/MemcachedAdapter.php
+6-6Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ class MemcachedAdapter extends AbstractAdapter
4848
public function __construct(\Memcached $client, string $namespace = '', int $defaultLifetime = 0, MarshallerInterface $marshaller = null)
4949
{
5050
if (!static::isSupported()) {
51-
throw new CacheException('Memcached >= 2.2.0 is required');
51+
throw new CacheException('Memcached >= 2.2.0 is required.');
5252
}
5353
if ('Memcached' === \get_class($client)) {
5454
$opt = $client->getOption(\Memcached::OPT_SERIALIZER);
@@ -95,7 +95,7 @@ public static function createConnection($servers, array $options = [])
9595
throw new InvalidArgumentException(sprintf('MemcachedAdapter::createClient() expects array or string as first argument, %s given.', \gettype($servers)));
9696
}
9797
if (!static::isSupported()) {
98-
throw new CacheException('Memcached >= 2.2.0 is required');
98+
throw new CacheException('Memcached >= 2.2.0 is required.');
9999
}
100100
set_error_handler(function ($type, $msg, $file, $line) { throw new \ErrorException($msg, 0, $type, $file, $line); });
101101
try {
@@ -110,7 +110,7 @@ public static function createConnection($servers, array $options = [])
110110
continue;
111111
}
112112
if (0 !== strpos($dsn, 'memcached:')) {
113-
throw new InvalidArgumentException(sprintf('Invalid Memcached DSN: %s does not start with "memcached:"', $dsn));
113+
throw new InvalidArgumentException(sprintf('Invalid Memcached DSN: %s does not start with "memcached:".', $dsn));
114114
}
115115
$params = preg_replace_callback('#^memcached:(//)?(?:([^@]*+)@)?#', function ($m) use (&$username, &$password) {
116116
if (!empty($m[2])) {
@@ -120,15 +120,15 @@ public static function createConnection($servers, array $options = [])
120120
return 'file:'.($m[1] ?? '');
121121
}, $dsn);
122122
if (false === $params = parse_url($params)) {
123-
throw new InvalidArgumentException(sprintf('Invalid Memcached DSN: %s', $dsn));
123+
throw new InvalidArgumentException(sprintf('Invalid Memcached DSN: %s.', $dsn));
124124
}
125125
$query = $hosts = [];
126126
if (isset($params['query'])) {
127127
parse_str($params['query'], $query);
128128

129129
if (isset($query['host'])) {
130130
if (!\is_array($hosts = $query['host'])) {
131-
throw new InvalidArgumentException(sprintf('Invalid Memcached DSN: %s', $dsn));
131+
throw new InvalidArgumentException(sprintf('Invalid Memcached DSN: %s.', $dsn));
132132
}
133133
foreach ($hosts as $host => $weight) {
134134
if (false === $port = strrpos($host, ':')) {
@@ -147,7 +147,7 @@ public static function createConnection($servers, array $options = [])
147147
}
148148
}
149149
if (!isset($params['host']) && !isset($params['path'])) {
150-
throw new InvalidArgumentException(sprintf('Invalid Memcached DSN: %s', $dsn));
150+
throw new InvalidArgumentException(sprintf('Invalid Memcached DSN: %s.', $dsn));
151151
}
152152
if (isset($params['path']) && preg_match('#/(\d+)$#', $params['path'], $m)) {
153153
$params['weight'] = $m[1];

‎src/Symfony/Component/Cache/Adapter/PdoAdapter.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Cache/Adapter/PdoAdapter.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ public function __construct($connOrDsn, string $namespace = '', int $defaultLife
7373

7474
if ($connOrDsn instanceof \PDO) {
7575
if (\PDO::ERRMODE_EXCEPTION !== $connOrDsn->getAttribute(\PDO::ATTR_ERRMODE)) {
76-
throw new InvalidArgumentException(sprintf('"%s" requires PDO error mode attribute be set to throw Exceptions (i.e. $pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION))', __CLASS__));
76+
throw new InvalidArgumentException(sprintf('"%s" requires PDO error mode attribute be set to throw Exceptions (i.e. $pdo->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION)).', __CLASS__));
7777
}
7878

7979
$this->conn = $connOrDsn;

‎src/Symfony/Component/Cache/Adapter/PhpFilesAdapter.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Cache/Adapter/PhpFilesAdapter.php
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -264,7 +264,7 @@ protected function doSave(array $values, int $lifetime)
264264
}
265265

266266
if (!$ok && !is_writable($this->directory)) {
267-
throw new CacheException(sprintf('Cache directory is not writable (%s)', $this->directory));
267+
throw new CacheException(sprintf('Cache directory is not writable (%s).', $this->directory));
268268
}
269269

270270
return $ok;

‎src/Symfony/Component/Notifier/Bridge/Telegram/TelegramTransportFactory.php

Copy file name to clipboardExpand all lines: src/Symfony/Component/Notifier/Bridge/Telegram/TelegramTransportFactory.php
+2-2Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -50,11 +50,11 @@ protected function getSupportedSchemes(): array
5050
private function getToken(Dsn $dsn): string
5151
{
5252
if (null === $dsn->getUser() && null === $dsn->getPassword()) {
53-
throw new IncompleteDsnException('Missing token');
53+
throw new IncompleteDsnException('Missing token.');
5454
}
5555

5656
if (null === $dsn->getPassword()) {
57-
throw new IncompleteDsnException('Malformed token');
57+
throw new IncompleteDsnException('Malformed token.');
5858
}
5959

6060
return sprintf('%s:%s', $dsn->getUser(), $dsn->getPassword());

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.