public function addToPackages($dir)
    {
        $files = glob($dir.'/*');

        $packageViews = Config::get('cms.package-menus');

        if (is_null($packageViews)) {
            $packageViews = [];
        }

        foreach ($files as $view) {
            array_push($packageViews, $view);
        }

        return Config::set('cms.package-menus', $packageViews);
    }
public function addToPackages($dir)
    {
        $files = glob($dir.'/*');

        $packageViews = Config::get('cms.package-menus');

        if (is_null($packageViews)) {
            $packageViews = [];
        }

        foreach ($files as $view) {
            array_push($packageViews, $view);
        }

        return Config::set('cms.package-menus', $packageViews);
    }
public function addToPackages ( $ dir ) { $ files = glob ( $ dir . '/*' ) ; $ packageViews = Config :: get ( 'cms.package-menus' ) ; if ( is_null ( $ packageViews ) ) { $ packageViews = [ ] ; } foreach ( $ files as $ view ) { array_push ( $ packageViews , $ view ) ; } return Config :: set ( 'cms.package-menus' , $ packageViews ) ; }
Add these views to the packages.

@param string $dir
Add these views to the packages .