From d5c3e2784a3fd6a01eb70d5e313777d552d8913c Mon Sep 17 00:00:00 2001 From: Dieter Holvoet Date: Thu, 6 Jul 2023 11:38:59 +0200 Subject: [PATCH] Fix 'TypeError: SymfonyStyle::ask(): Argument #2 ($default) must be of type ?string, int given' --- src/Commands/field/FieldCreateCommands.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Commands/field/FieldCreateCommands.php b/src/Commands/field/FieldCreateCommands.php index 1dc687c8e4..8f7ff3778f 100644 --- a/src/Commands/field/FieldCreateCommands.php +++ b/src/Commands/field/FieldCreateCommands.php @@ -335,7 +335,7 @@ protected function askCardinality(): int $limit = FieldStorageDefinitionInterface::CARDINALITY_UNLIMITED; while ($cardinality === 'Limited' && $limit < 1) { - $limit = (int) $this->io()->ask('Allowed number of values', 1); + $limit = (int) $this->io()->ask('Allowed number of values', '1'); } return $limit;