Skip to content

Commit de6f26f

Browse files
committed
[Turbo] Fix Turbo CI (PHPStan & Functional tests)
1 parent f708759 commit de6f26f

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/Turbo/src/Bridge/Mercure/Broadcaster.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,12 @@ public function broadcast(object $entity, string $action, array $options): void
6868
$topics = [];
6969

7070
foreach ((array) ($options['topics'] ?? []) as $topic) {
71+
// @phpstan-ignore function.alreadyNarrowedType ($topic should always be a string given the PHPDoc... could be removed in 3.x)
72+
if (!\is_string($topic)) {
73+
$topics[] = $topic;
74+
continue;
75+
}
76+
7177
if (!str_starts_with($topic, '@=')) {
7278
$topics[] = $topic;
7379
continue;

0 commit comments

Comments
 (0)