MIF_E31222882/app/Providers/AppServiceProvider.php

29 lines
533 B
PHP

<?php
namespace App\Providers;
use Carbon\Carbon;
use Illuminate\Support\ServiceProvider;
use App\Services\MidtransService;
class AppServiceProvider extends ServiceProvider
{
/**
* Register any application services.
*/
public function register(): void
{
$this->app->singleton(MidtransService::class, function ($app) {
return new MidtransService();
});
}
/**
* Bootstrap any application services.
*/
public function boot()
{
Carbon::setLocale('id');
}
}