src/Webpage/Traits/HasParent.php
public function getFullPathAttribute()
    {
        $pathSections = explode('/', $this->getFullPath());

        $slugsToExclude = array_wrap($this->domainMappedFolders);

        $finalSlug = collect($pathSections)
            ->filter()
            ->reject(function ($slug) use ($slugsToExclude) {
                return in_array($slug, $slugsToExclude);
            })
            ->implode('/');

        return str_start($finalSlug, '/');
    }
public function getFullPathAttribute()
    {
        $pathSections = explode('/', $this->getFullPath());

        $slugsToExclude = array_wrap($this->domainMappedFolders);

        $finalSlug = collect($pathSections)
            ->filter()
            ->reject(function ($slug) use ($slugsToExclude) {
                return in_array($slug, $slugsToExclude);
            })
            ->implode('/');

        return str_start($finalSlug, '/');
    }
public function getFullPathAttribute ( ) { $ pathSections = explode ( '/' , $ this -> getFullPath ( ) ) ; $ slugsToExclude = array_wrap ( $ this -> domainMappedFolders ) ; $ finalSlug = collect ( $ pathSections ) -> filter ( ) -> reject ( function ( $ slug ) use ( $ slugsToExclude ) { return in_array ( $ slug , $ slugsToExclude ) ; } ) -> implode ( '/' ) ; return str_start ( $ finalSlug , '/' ) ; }
Add full path attribute.

@return string Full path
Add full path attribute .