incubator-wink-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bryant Luk (JIRA)" <>
Subject [jira] Commented: (WINK-235) Fix issue with using Locale objects inside ResponseBuilder
Date Mon, 30 Nov 2009 22:25:25 GMT


Bryant Luk commented on WINK-235:

Locale.toString() was called in the FlushResultHandler (in flushHeaders) but it was an incorrect
format (my mistake in earlier description).

"en_US" is incorrect (which is what Locale.toString() produces).  Should really use HeaderUtils.localeToLanguage()
instead in ResponseBuilderImpl to produce "en-US".

public Response getSomething() {
  return Response.ok("Hello world!").language(Locale.US).build();

> Fix issue with using Locale objects inside ResponseBuilder
> ----------------------------------------------------------
>                 Key: WINK-235
>                 URL:
>             Project: Wink
>          Issue Type: Bug
>          Components: Common
>    Affects Versions: 0.1, 1.0
>            Reporter: Bryant Luk
>            Assignee: Bryant Luk
>             Fix For: 1.1
> Using a Locale object will not always produce the correct HTTP response header.  Should
explicitly call toString on it in the ResponseBuilder for the Content-Language header to be

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message