>     public AuthenticationResponse apply(HttpResponse from) {
>        releasePayload(from);
> -      Builder<String, URI> builder = ImmutableMap.builder();
> -      for (Entry<String, String> entry : from.getHeaders().entries()) {
> -         if (entry.getKey().endsWith(URL_SUFFIX))
> -            builder.put(entry.getKey(), getURI(entry.getValue()));
> +
> +      // HTTP headers are case in-sensitive (RFC 2616) so we must allow for 
> that when looking an header names for the URL keyword
> +      //FIXME When Apache commons-collections 4 is out of Snapshot it will 
> provide generics for CaseInsensitiveMap 
> +      final CaseInsensitiveMap services = new CaseInsensitiveMap();
> +      for (final Entry<String, String> entry : from.getHeaders().entries()) {
> +         if (entry.getKey().toLowerCase().endsWith(URL_SUFFIX.toLowerCase()))
> +            services.put(entry.getKey(), getURI(entry.getValue()));

@everett-toews I believe a Comparator suffices:

https://gist.github.com/andrewgaul/6109765

---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/76/files#r5467553

Reply via email to