Fix exception message in Doctrine Messenger
This commit is contained in:
parent
c966016a37
commit
ae0c6344b4
@ -86,13 +86,13 @@ class Connection
|
|||||||
// check for extra keys in options
|
// check for extra keys in options
|
||||||
$optionsExtraKeys = array_diff(array_keys($options), array_keys(self::DEFAULT_OPTIONS));
|
$optionsExtraKeys = array_diff(array_keys($options), array_keys(self::DEFAULT_OPTIONS));
|
||||||
if (0 < \count($optionsExtraKeys)) {
|
if (0 < \count($optionsExtraKeys)) {
|
||||||
throw new InvalidArgumentException(sprintf('Unknown option found : [%s]. Allowed options are [%s]', implode(', ', $optionsExtraKeys), implode(', ', self::DEFAULT_OPTIONS)));
|
throw new InvalidArgumentException(sprintf('Unknown option found : [%s]. Allowed options are [%s]', implode(', ', $optionsExtraKeys), implode(', ', array_keys(self::DEFAULT_OPTIONS))));
|
||||||
}
|
}
|
||||||
|
|
||||||
// check for extra keys in options
|
// check for extra keys in options
|
||||||
$queryExtraKeys = array_diff(array_keys($query), array_keys(self::DEFAULT_OPTIONS));
|
$queryExtraKeys = array_diff(array_keys($query), array_keys(self::DEFAULT_OPTIONS));
|
||||||
if (0 < \count($queryExtraKeys)) {
|
if (0 < \count($queryExtraKeys)) {
|
||||||
throw new InvalidArgumentException(sprintf('Unknown option found in DSN: [%s]. Allowed options are [%s]', implode(', ', $queryExtraKeys), implode(', ', self::DEFAULT_OPTIONS)));
|
throw new InvalidArgumentException(sprintf('Unknown option found in DSN: [%s]. Allowed options are [%s]', implode(', ', $queryExtraKeys), implode(', ', array_keys(self::DEFAULT_OPTIONS))));
|
||||||
}
|
}
|
||||||
|
|
||||||
return $configuration;
|
return $configuration;
|
||||||
|
Reference in New Issue
Block a user