protected function _extractFinder($options)
    {
        $type = !empty($options['finder']) ? $options['finder'] : 'all';
        unset($options['finder'], $options['maxLimit']);

        if (is_array($type)) {
            $options = (array)current($type) + $options;
            $type = key($type);
        }

        return [$type, $options];
    }
protected function _extractFinder($options)
    {
        $type = !empty($options['finder']) ? $options['finder'] : 'all';
        unset($options['finder'], $options['maxLimit']);

        if (is_array($type)) {
            $options = (array)current($type) + $options;
            $type = key($type);
        }

        return [$type, $options];
    }
protected function _extractFinder ( $ options ) { $ type = ! empty ( $ options [ 'finder' ] ) ? $ options [ 'finder' ] : 'all' ; unset ( $ options [ 'finder' ] , $ options [ 'maxLimit' ] ) ; if ( is_array ( $ type ) ) { $ options = ( array ) current ( $ type ) + $ options ; $ type = key ( $ type ) ; } return [ $ type , $ options ] ; }
Extracts the finder name and options out of the provided pagination options.

@param array $options the pagination options.
@return array An array containing in the first position the finder name
and in the second the options to be passed to it.
Extracts the finder name and options out of the provided pagination options .