From 1420976bea0e0ea3ded765c33917c80b6e35ba81 Mon Sep 17 00:00:00 2001 From: Hugo Alliaume Date: Sat, 17 Aug 2024 21:26:56 +0200 Subject: [PATCH] chore: run PHP-CS-Fixer --- src/Icons/src/Twig/UXIconRuntime.php | 1 + .../tests/Unit/Twig/LiveComponentRuntimeTest.php | 8 ++++---- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/Icons/src/Twig/UXIconRuntime.php b/src/Icons/src/Twig/UXIconRuntime.php index cac051aea8..7276ac0864 100644 --- a/src/Icons/src/Twig/UXIconRuntime.php +++ b/src/Icons/src/Twig/UXIconRuntime.php @@ -40,6 +40,7 @@ public function renderIcon(string $name, array $attributes = []): string } catch (IconNotFoundException $e) { if ($this->ignoreNotFound) { $this->logger?->warning($e->getMessage()); + return ''; } diff --git a/src/LiveComponent/tests/Unit/Twig/LiveComponentRuntimeTest.php b/src/LiveComponent/tests/Unit/Twig/LiveComponentRuntimeTest.php index 654ee92e78..30c3ba8cbb 100644 --- a/src/LiveComponent/tests/Unit/Twig/LiveComponentRuntimeTest.php +++ b/src/LiveComponent/tests/Unit/Twig/LiveComponentRuntimeTest.php @@ -28,17 +28,17 @@ public function testGetLiveAction(): void $this->assertSame('data-action="live#action" data-live-prop1-param="val1" data-live-some-prop-param="val2" data-live-action-param="action-name"', $props); $props = $runtime->liveAction('action-name', ['prop1' => 'val1', 'prop2' => 'val2'], ['debounce' => 300]); - $this->assertSame('data-action="live#action" data-live-prop1-param="val1" data-live-prop2-param="val2" data-live-action-param="debounce(300)|action-name"', \html_entity_decode($props)); + $this->assertSame('data-action="live#action" data-live-prop1-param="val1" data-live-prop2-param="val2" data-live-action-param="debounce(300)|action-name"', html_entity_decode($props)); $this->assertSame('data-action="live#action" data-live-prop1-param="val1" data-live-prop2-param="val2" data-live-action-param="debounce(300)|action-name"', $props); $props = $runtime->liveAction('action-name:prevent', ['pro1' => 'val1', 'prop2' => 'val2'], ['debounce' => 300]); - $this->assertSame('data-action="live#action:prevent" data-live-pro1-param="val1" data-live-prop2-param="val2" data-live-action-param="debounce(300)|action-name"', \html_entity_decode($props)); + $this->assertSame('data-action="live#action:prevent" data-live-pro1-param="val1" data-live-prop2-param="val2" data-live-action-param="debounce(300)|action-name"', html_entity_decode($props)); $this->assertSame('data-action="live#action:prevent" data-live-pro1-param="val1" data-live-prop2-param="val2" data-live-action-param="debounce(300)|action-name"', $props); $props = $runtime->liveAction('action-name:prevent', [], ['debounce' => 300]); - $this->assertSame('data-action="live#action:prevent" data-live-action-param="debounce(300)|action-name"', \html_entity_decode($props)); + $this->assertSame('data-action="live#action:prevent" data-live-action-param="debounce(300)|action-name"', html_entity_decode($props)); $props = $runtime->liveAction('action-name', [], [], 'keydown.esc'); - $this->assertSame('data-action="keydown.esc->live#action" data-live-action-param="action-name"', \html_entity_decode($props)); + $this->assertSame('data-action="keydown.esc->live#action" data-live-action-param="action-name"', html_entity_decode($props)); } }