![]() Server : Apache/2.4.62 (Unix) OpenSSL/1.0.2k-fips System : Linux server1.richineiserver.com 3.10.0-1160.119.1.el7.x86_64 #1 SMP Tue Jun 4 14:43:51 UTC 2024 x86_64 User : fdshops ( 1003) PHP Version : 8.2.21 Disable Function : NONE Directory : /home/fdshops/public_html/vendor/laravel/framework/src/Illuminate/Mail/ |
<?php namespace Illuminate\Mail; use Illuminate\Contracts\Support\DeferrableProvider; use Illuminate\Support\ServiceProvider; class MailServiceProvider extends ServiceProvider implements DeferrableProvider { /** * Register the service provider. * * @return void */ public function register() { $this->registerIlluminateMailer(); $this->registerMarkdownRenderer(); } /** * Register the Illuminate mailer instance. * * @return void */ protected function registerIlluminateMailer() { $this->app->singleton('mail.manager', function ($app) { return new MailManager($app); }); $this->app->bind('mailer', function ($app) { return $app->make('mail.manager')->mailer(); }); } /** * Register the Markdown renderer instance. * * @return void */ protected function registerMarkdownRenderer() { if ($this->app->runningInConsole()) { $this->publishes([ __DIR__.'/resources/views' => $this->app->resourcePath('views/vendor/mail'), ], 'laravel-mail'); } $this->app->singleton(Markdown::class, function ($app) { $config = $app->make('config'); return new Markdown($app->make('view'), [ 'theme' => $config->get('mail.markdown.theme', 'default'), 'paths' => $config->get('mail.markdown.paths', []), ]); }); } /** * Get the services provided by the provider. * * @return array */ public function provides() { return [ 'mail.manager', 'mailer', Markdown::class, ]; } }