Skip to content

Commit 104b20a

Browse files
Merge branch 'master' into develop
2 parents e4679a0 + cd7d4fa commit 104b20a

File tree

14 files changed

+13
-30
lines changed

14 files changed

+13
-30
lines changed

.github/workflows/php-cs-fixer.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ jobs:
1515
ref: ${{ github.head_ref }}
1616

1717
- name: Run php-cs-fixer
18-
uses: docker://oskarstark/php-cs-fixer-ga:3.0.0
18+
uses: docker://oskarstark/php-cs-fixer-ga
1919
with:
2020
args: --config=.php-cs-fixer.dist.php --allow-risky=yes
2121

src/Console/Commands/AbstractCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ protected function validateName()
2424
if (!$this->theme) {
2525
$this->error("Theme with name {$name} does not exists!");
2626

27-
exit();
27+
exit;
2828
}
2929
}
3030
}

src/Console/Commands/ListThemes.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ public function handle()
4040
'vendor' => $theme->getVendor(),
4141
'version' => $theme->getVersion(),
4242
'description' => $theme->getDescription(),
43-
'extends' => $theme->getParent() ? $theme->getParent() : '',
43+
'extends' => $theme->getParent() ? $theme->getParent()->getName() : '',
4444
'default' => $theme->getName() === config('themes-manager.fallback_theme') ? 'X' : '',
4545
];
4646
}

src/Console/Generators/MakeTheme.php

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
namespace Hexadog\ThemesManager\Console\Generators;
44

5-
use Exception;
65
use Hexadog\ThemesManager\Console\Commands\Traits\BlockMessage;
76
use Hexadog\ThemesManager\Console\Commands\Traits\SectionMessage;
87
use Hexadog\ThemesManager\Facades\ThemesManager;
@@ -86,7 +85,7 @@ public function handle()
8685
$this->generateTheme();
8786

8887
$this->sectionMessage('Themes Manager', 'Theme successfully created');
89-
} catch (Exception $e) {
88+
} catch (\Exception $e) {
9089
$this->error($e->getMessage());
9190
}
9291
}
@@ -240,7 +239,7 @@ private function generateTheme()
240239

241240
// Make directory
242241
if ($this->files->isDirectory($directory)) {
243-
throw new Exception("Theme {$this->theme['name']} already exists");
242+
throw new \Exception("Theme {$this->theme['name']} already exists");
244243
}
245244
$this->files->makeDirectory($directory, 0755, true);
246245

src/Events/ThemeDisabled.php

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,6 @@ class ThemeDisabled
99
*/
1010
public $theme;
1111

12-
/**
13-
* @param $theme
14-
*/
1512
public function __construct($theme)
1613
{
1714
$this->theme = $theme;

src/Events/ThemeDisabling.php

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,6 @@ class ThemeDisabling
99
*/
1010
public $theme;
1111

12-
/**
13-
* @param $theme
14-
*/
1512
public function __construct($theme)
1613
{
1714
$this->theme = $theme;

src/Events/ThemeEnabled.php

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,6 @@ class ThemeEnabled
99
*/
1010
public $theme;
1111

12-
/**
13-
* @param $theme
14-
*/
1512
public function __construct($theme)
1613
{
1714
$this->theme = $theme;

src/Events/ThemeEnabling.php

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,6 @@ class ThemeEnabling
99
*/
1010
public $theme;
1111

12-
/**
13-
* @param $theme
14-
*/
1512
public function __construct($theme)
1613
{
1714
$this->theme = $theme;

src/Exceptions/ThemeLoaderException.php

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,7 @@
22

33
namespace Hexadog\ThemesManager\Exceptions;
44

5-
use RuntimeException;
6-
7-
class ThemeLoaderException extends RuntimeException
5+
class ThemeLoaderException extends \RuntimeException
86
{
97
/**
108
* @return \Hexadog\ThemesManager\Exceptions\ThemeLoaderException

src/Helpers/Json.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,6 @@ public function save(): bool
201201
/**
202202
* Get the specified attribute from json file.
203203
*
204-
* @param $key
205204
* @param null $default
206205
*
207206
* @return mixed

0 commit comments

Comments
 (0)