@@ -11,11 +11,11 @@ trait ConsoleTools
11
11
*
12
12
* @return void
13
13
*/
14
- protected function publishesMigrations (string $ package ): void
14
+ protected function publishesMigrations (string $ package, bool $ isModule = false ): void
15
15
{
16
16
$ namespace = str_replace ('laravel- ' , '' , $ package );
17
17
$ namespace = str_replace (['/ ' , '\\' , '. ' , '_ ' ], '- ' , $ namespace );
18
- $ basePath = starts_with ( $ package , ' cortex ' ) ? $ this ->app ->path ($ package )
18
+ $ basePath = $ isModule ? $ this ->app ->path ($ package )
19
19
: $ this ->app ->basePath ('vendor/ ' .$ package );
20
20
21
21
if (file_exists ($ path = $ basePath .'/database/migrations ' )) {
@@ -40,11 +40,11 @@ protected function publishesMigrations(string $package): void
40
40
*
41
41
* @return void
42
42
*/
43
- protected function publishesConfig (string $ package ): void
43
+ protected function publishesConfig (string $ package, bool $ isModule = false ): void
44
44
{
45
45
$ namespace = str_replace ('laravel- ' , '' , $ package );
46
46
$ namespace = str_replace (['/ ' , '\\' , '. ' , '_ ' ], '- ' , $ namespace );
47
- $ basePath = starts_with ( $ package , ' cortex ' ) ? $ this ->app ->path ($ package )
47
+ $ basePath = $ isModule ? $ this ->app ->path ($ package )
48
48
: $ this ->app ->basePath ('vendor/ ' .$ package );
49
49
50
50
if (file_exists ($ path = $ basePath .'/config/config.php ' )) {
@@ -57,11 +57,11 @@ protected function publishesConfig(string $package): void
57
57
*
58
58
* @return void
59
59
*/
60
- protected function publishesViews (string $ package ): void
60
+ protected function publishesViews (string $ package, bool $ isModule = false ): void
61
61
{
62
62
$ namespace = str_replace ('laravel- ' , '' , $ package );
63
63
$ namespace = str_replace (['/ ' , '\\' , '. ' , '_ ' ], '- ' , $ namespace );
64
- $ basePath = starts_with ( $ package , ' cortex ' ) ? $ this ->app ->path ($ package )
64
+ $ basePath = $ isModule ? $ this ->app ->path ($ package )
65
65
: $ this ->app ->basePath ('vendor/ ' .$ package );
66
66
67
67
if (file_exists ($ path = $ basePath .'/resources/views ' )) {
@@ -74,11 +74,11 @@ protected function publishesViews(string $package): void
74
74
*
75
75
* @return void
76
76
*/
77
- protected function publishesLang (string $ package ): void
77
+ protected function publishesLang (string $ package, bool $ isModule = false ): void
78
78
{
79
79
$ namespace = str_replace ('laravel- ' , '' , $ package );
80
80
$ namespace = str_replace (['/ ' , '\\' , '. ' , '_ ' ], '- ' , $ namespace );
81
- $ basePath = starts_with ( $ package , ' cortex ' ) ? $ this ->app ->path ($ package )
81
+ $ basePath = $ isModule ? $ this ->app ->path ($ package )
82
82
: $ this ->app ->basePath ('vendor/ ' .$ package );
83
83
84
84
if (file_exists ($ path = $ basePath .'/resources/lang ' )) {
0 commit comments