app/Carbon.php
public function local(): Carbon
    {
        $locale   = app(LocaleInterface::class)->code();
        $timezone = Auth::user()->getPreference('TIMEZONE', Site::getPreference('TIMEZONE', 'UTC'));

        return $this->locale($locale)->setTimezone($timezone);
    }
public function local(): Carbon
    {
        $locale   = app(LocaleInterface::class)->code();
        $timezone = Auth::user()->getPreference('TIMEZONE', Site::getPreference('TIMEZONE', 'UTC'));

        return $this->locale($locale)->setTimezone($timezone);
    }
public function local ( ) : Carbon { $ locale = app ( LocaleInterface :: class ) -> code ( ) ; $ timezone = Auth :: user ( ) -> getPreference ( 'TIMEZONE' , Site :: getPreference ( 'TIMEZONE' , 'UTC' ) ) ; return $ this -> locale ( $ locale ) -> setTimezone ( $ timezone ) ; }
Create a local timestamp for the current user.

@return Carbon
Create a local timestamp for the current user .