src/Auth/AclRepository.php
protected function loadAclModules()
    {
        // Gather all modules with any menu inherent or overridden presence
        // and store them locally according to their nature.

        foreach ($this->core->modules()->getModules() as $moduleKey => $module) {

            $presencesForModule = $module->getAclPresence();

            // If a module has no presence, skip it
            if ( ! $presencesForModule) {
                continue;
            }

            if ( ! $this->modulePresences->has($moduleKey)) {
                $this->modulePresences->put($moduleKey, new Collection);
            }

            foreach ($this->normalizeAclPresence($presencesForModule) as $presence) {

                if ( ! $presence) {
                    // @codeCoverageIgnoreStart
                    continue;
                    // @codeCoverageIgnoreEnd
                }

                $this->presences->push($presence);
                $this->modulePresences->get($moduleKey)->push($presence);
            }
        }

        return $this;
    }
protected function loadAclModules()
    {
        // Gather all modules with any menu inherent or overridden presence
        // and store them locally according to their nature.

        foreach ($this->core->modules()->getModules() as $moduleKey => $module) {

            $presencesForModule = $module->getAclPresence();

            // If a module has no presence, skip it
            if ( ! $presencesForModule) {
                continue;
            }

            if ( ! $this->modulePresences->has($moduleKey)) {
                $this->modulePresences->put($moduleKey, new Collection);
            }

            foreach ($this->normalizeAclPresence($presencesForModule) as $presence) {

                if ( ! $presence) {
                    // @codeCoverageIgnoreStart
                    continue;
                    // @codeCoverageIgnoreEnd
                }

                $this->presences->push($presence);
                $this->modulePresences->get($moduleKey)->push($presence);
            }
        }

        return $this;
    }
protected function loadAclModules ( ) { // Gather all modules with any menu inherent or overridden presence // and store them locally according to their nature. foreach ( $ this -> core -> modules ( ) -> getModules ( ) as $ moduleKey => $ module ) { $ presencesForModule = $ module -> getAclPresence ( ) ; // If a module has no presence, skip it if ( ! $ presencesForModule ) { continue ; } if ( ! $ this -> modulePresences -> has ( $ moduleKey ) ) { $ this -> modulePresences -> put ( $ moduleKey , new Collection ) ; } foreach ( $ this -> normalizeAclPresence ( $ presencesForModule ) as $ presence ) { if ( ! $ presence ) { // @codeCoverageIgnoreStart continue ; // @codeCoverageIgnoreEnd } $ this -> presences -> push ( $ presence ) ; $ this -> modulePresences -> get ( $ moduleKey ) -> push ( $ presence ) ; } } return $ this ; }
Loads the ACL presences from modules and stores it normalized in the main presences collection.

@return $this
Loads the ACL presences from modules and stores it normalized in the main presences collection .