Skip to content
Snippets Groups Projects
Unverified Commit b62626bc authored by Sergei Morozov's avatar Sergei Morozov
Browse files

Improve handling argument types in ReservedWordsCommand

parent 6099ae8c
No related branches found
No related tags found
Loading
......@@ -33,6 +33,7 @@ use function array_keys;
use function assert;
use function count;
use function implode;
use function is_array;
use function is_string;
use function trigger_error;
......@@ -149,7 +150,14 @@ EOT
{
$conn = $this->getConnection($input);
$keywordLists = (array) $input->getOption('list');
$keywordLists = $input->getOption('list');
if (is_string($keywordLists)) {
$keywordLists = [$keywordLists];
} elseif (! is_array($keywordLists)) {
$keywordLists = [];
}
if (! $keywordLists) {
$keywordLists = [
'mysql',
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment