Skip to content

Commit 5426d18

Browse files
dermatzMorgy93Copilot
authored
fix: normalize theme name check to be case-insensitive for Hyva themes (#38)
* fix: normalize theme name check to be case-insensitive for Hyva themes * Apply suggestions from code review Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Thomas Hauschild <7961978+Morgy93@users.noreply.github.com> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent caacb69 commit 5426d18

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/Service/ThemeBuilder/HyvaThemes/Builder.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ public function detect(string $themePath): bool
3737
// Check theme.xml for Hyva theme declaration
3838
if ($this->fileDriver->isExists($themePath . '/theme.xml')) {
3939
$themeXmlContent = $this->fileDriver->fileGetContents($themePath . '/theme.xml');
40-
if (str_contains($themeXmlContent, 'Hyva')) {
40+
if (stripos($themeXmlContent, 'hyva') !== false) {
4141
return true;
4242
}
4343
}

src/Service/ThemeBuilder/TailwindCSS/Builder.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ public function detect(string $themePath): bool
3737
// Check for theme.xml file in theme folder and ensure it's not a Hyva theme
3838
if ($this->fileDriver->isExists($themePath . '/theme.xml')) {
3939
$themeXmlContent = $this->fileDriver->fileGetContents($themePath . '/theme.xml');
40-
if (!str_contains($themeXmlContent, 'Hyva')) {
40+
if (stripos($themeXmlContent, 'hyva') === false) {
4141
return true;
4242
}
4343
}

0 commit comments

Comments
 (0)