public function find($template)
    {
        is_array($template) and $template = array_filter($template, 'is_string');
        if ((! is_string($template) && ! is_array($template)) || empty($template)) {
            throw new InvalidArgumentException(
                'Template name must be a string or an array of strings.'
            );
        }
        if (is_array($template)) {
            return $this->findMany($template);
        }
        $parse = $this->parseName($template);
        if ($parse['dir']) {
            return $this->findInDir($parse['dir'], $parse['file']);
        }

        return $parse['file'] ? $this->scanFor($parse['file']) : false;
    }
public function find($template)
    {
        is_array($template) and $template = array_filter($template, 'is_string');
        if ((! is_string($template) && ! is_array($template)) || empty($template)) {
            throw new InvalidArgumentException(
                'Template name must be a string or an array of strings.'
            );
        }
        if (is_array($template)) {
            return $this->findMany($template);
        }
        $parse = $this->parseName($template);
        if ($parse['dir']) {
            return $this->findInDir($parse['dir'], $parse['file']);
        }

        return $parse['file'] ? $this->scanFor($parse['file']) : false;
    }
public function find ( $ template ) { is_array ( $ template ) and $ template = array_filter ( $ template , 'is_string' ) ; if ( ( ! is_string ( $ template ) && ! is_array ( $ template ) ) || empty ( $ template ) ) { throw new InvalidArgumentException ( 'Template name must be a string or an array of strings.' ) ; } if ( is_array ( $ template ) ) { return $ this -> findMany ( $ template ) ; } $ parse = $ this -> parseName ( $ template ) ; if ( $ parse [ 'dir' ] ) { return $ this -> findInDir ( $ parse [ 'dir' ] , $ parse [ 'file' ] ) ; } return $ parse [ 'file' ] ? $ this -> scanFor ( $ parse [ 'file' ] ) : false ; }
Find a template

@param  string|array             $template
@return string|boolean           Template path if found or false if not
@throws InvalidArgumentException
Find a template