protected function parseStates(array $states)
    {
        $newStates = array();
        foreach ($states as $key => $state) {
            if (null === $state) {
                $newStates[] = $key;
            } elseif (self::CFG_STATE_DISABLE !== $state) {
                $newStates[] = $state;
            } elseif (null !== $index = array_search($key, $newStates)) {
                unset($newStates[$index]);
            }
        }

        return $newStates;
    }
protected function parseStates(array $states)
    {
        $newStates = array();
        foreach ($states as $key => $state) {
            if (null === $state) {
                $newStates[] = $key;
            } elseif (self::CFG_STATE_DISABLE !== $state) {
                $newStates[] = $state;
            } elseif (null !== $index = array_search($key, $newStates)) {
                unset($newStates[$index]);
            }
        }

        return $newStates;
    }
protected function parseStates ( array $ states ) { $ newStates = array ( ) ; foreach ( $ states as $ key => $ state ) { if ( null === $ state ) { $ newStates [ ] = $ key ; } elseif ( self :: CFG_STATE_DISABLE !== $ state ) { $ newStates [ ] = $ state ; } elseif ( null !== $ index = array_search ( $ key , $ newStates ) ) { unset ( $ newStates [ $ index ] ) ; } } return $ newStates ; }
Allows the disabling of states

@param array $states

@return array
Allows the disabling of states