We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b9c8e85 commit c1fe894Copy full SHA for c1fe894
1 file changed
src/Model/ThemeList.php
@@ -27,4 +27,15 @@ public function getAllThemes(): array
27
{
28
return $this->magentoThemeList->getItems();
29
}
30
+
31
+ public function getThemeByCode(string $code): ?\Magento\Framework\View\Design\ThemeInterface
32
+ {
33
+ $themes = $this->getAllThemes();
34
+ foreach ($themes as $theme) {
35
+ if ($theme->getCode() === $code) {
36
+ return $theme;
37
+ }
38
39
+ return null;
40
41
0 commit comments