Github user jwagenleitner commented on a diff in the pull request:

    https://github.com/apache/incubator-groovy/pull/124#discussion_r41644345
  
    --- Diff: subprojects/groovy-json/src/main/java/groovy/json/JsonOutput.java 
---
    @@ -119,12 +119,24 @@ public static String toJson(String s) {
          * @return a formatted date in the form of a string
          */
         public static String toJson(Date date) {
    +        dateFormat.setTimeZone(TimeZone.getTimeZone(DEFAULT_TIMEZONE));
    --- End diff --
    
    See note above, probably should new up a `SimpleDateFormat` here, might be 
better to provide a way to override the JSON_DATE_FORMAT that is used and 
construct a new format object using either the provide format string and fall 
back to JSON_DATE_FORMAT if not provided.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to