protected function getPrefixes()
    {
        $router = app(\Illuminate\Routing\Router::class);

        $this->prefixes = collect(
            explode('/', $router->getCurrentRoute()->getPrefix())
        );

        // Remove the last prefix if it matches the controller.
        $this->prefixes = $this->removeControllerFromPrefixes($this->prefixes)->filter();

        if ($this->prefixes->count() > 0) {
            $this->prefix = $this->prefixes->filter()->implode('.');
        }
    }
protected function getPrefixes()
    {
        $router = app(\Illuminate\Routing\Router::class);

        $this->prefixes = collect(
            explode('/', $router->getCurrentRoute()->getPrefix())
        );

        // Remove the last prefix if it matches the controller.
        $this->prefixes = $this->removeControllerFromPrefixes($this->prefixes)->filter();

        if ($this->prefixes->count() > 0) {
            $this->prefix = $this->prefixes->filter()->implode('.');
        }
    }
protected function getPrefixes ( ) { $ router = app ( \ Illuminate \ Routing \ Router :: class ) ; $ this -> prefixes = collect ( explode ( '/' , $ router -> getCurrentRoute ( ) -> getPrefix ( ) ) ) ; // Remove the last prefix if it matches the controller. $ this -> prefixes = $ this -> removeControllerFromPrefixes ( $ this -> prefixes ) -> filter ( ) ; if ( $ this -> prefixes -> count ( ) > 0 ) { $ this -> prefix = $ this -> prefixes -> filter ( ) -> implode ( '.' ) ; } }
Search for any prefixes attached to this route.

@return string
Search for any prefixes attached to this route .