File tree 1 file changed +12
-4
lines changed
1 file changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -390,19 +390,27 @@ protected function registerViews()
390
390
$ directories = scandir ($ vendorViewsPath );
391
391
foreach ($ directories as $ namespace ) {
392
392
if ($ namespace != '. ' && $ namespace != '.. ' ) {
393
- $ path = "{$ vendorViewsPath }/ {$ namespace }" ;
394
-
395
393
if (!empty (Config::get ('view.paths ' )) && is_array (Config::get ('view.paths ' ))) {
396
394
foreach (Config::get ('view.paths ' ) as $ viewPath ) {
397
395
if (is_dir ($ appPath = $ viewPath . '/vendor/ ' . $ namespace )) {
398
396
View::prependNamespace ($ namespace , $ appPath );
399
397
}
400
398
}
401
399
}
402
-
403
- View::prependNamespace ($ namespace , $ path );
404
400
}
405
401
}
406
402
}
403
+
404
+ // Update config mail.markdown.paths to work with mail views
405
+ $ mailViewsPath = $ this ->getPath ('resources/views/vendor/mail ' );
406
+ if (File::exists ($ vendorViewsPath ) && is_dir ($ mailViewsPath )) {
407
+ if (is_array (Config::get ('mail.markdown.paths ' ))) {
408
+ Config::set ('mail.markdown.paths ' , array_merge ([
409
+ $ mailViewsPath
410
+ ], Config::get ('mail.markdown.paths ' )));
411
+ } else {
412
+ Config::set ('mail.markdown.paths ' , $ mailViewsPath );
413
+ }
414
+ }
407
415
}
408
416
}
You can’t perform that action at this time.
0 commit comments