token_extraction.go
func FromMultiple(extractors ...RequestTokenExtractor) RequestTokenExtractor {
	return RequestTokenExtractorFunc(func(r *http.Request) (*jwt.JSONWebToken, error) {
		for _, e := range extractors {
			token, err := e.Extract(r)
			if err == ErrTokenNotFound {
				continue
			} else if err != nil {
				return nil, err
			}
			return token, nil
		}
		return nil, ErrTokenNotFound
	})
}
func FromMultiple(extractors ...RequestTokenExtractor) RequestTokenExtractor {
	return RequestTokenExtractorFunc(func(r *http.Request) (*jwt.JSONWebToken, error) {
		for _, e := range extractors {
			token, err := e.Extract(r)
			if err == ErrTokenNotFound {
				continue
			} else if err != nil {
				return nil, err
			}
			return token, nil
		}
		return nil, ErrTokenNotFound
	})
}
func FromMultiple ( extractors ... RequestTokenExtractor ) RequestTokenExtractor { return RequestTokenExtractorFunc ( func ( r * http . Request ) ( * jwt . JSONWebToken , error ) { for _ , e := range extractors { token , err := e . Extract ( r ) if err == ErrTokenNotFound { continue } else if err != nil { return nil , err } return token , nil } return nil , ErrTokenNotFound } ) }
// FromMultiple combines multiple extractors by chaining.
FromMultiple combines multiple extractors by chaining .