fix macro carbon

This commit is contained in:
nasser committed 2022-08-24 09:10:54 +04:30
1 parent d5e95d3579
commit 60446ea760
1 file changed
+4 -4
+4 -4
View File
@@ -76,6 +76,10 @@ class VertaServiceProvider extends ServiceProvider
public function boot() public function boot()
{ {
$this->loadValidators(); $this->loadValidators();
Carbon::macro('toJalali', function ($timezone = null) {
return new Verta($this, $timezone);
});
} }
/** /**
@@ -88,10 +92,6 @@ class VertaServiceProvider extends ServiceProvider
$this->app->bind('verta', function ($app) { $this->app->bind('verta', function ($app) {
return new Verta(); return new Verta();
}); });
Carbon::macro('toJalali', function ($timezone = null) {
return new Verta($this, $timezone);
});
} }
/** /**