| commit | 78a830a2eddd7b67c81401df225cd96bd2f5c97d | [log] [tgz] |
|---|---|---|
| author | cromwellian@google.com <cromwellian@google.com@8db76d5a-ed1c-0410-87a9-c151d255dfc7> | Sun Aug 22 14:49:19 2010 +0000 |
| committer | cromwellian@google.com <cromwellian@google.com@8db76d5a-ed1c-0410-87a9-c151d255dfc7> | Sun Aug 22 14:49:19 2010 +0000 |
| tree | 1668de908c7c240f721422ba02969bb3aaa963d8 | |
| parent | 597c304008e00a4f5a84ee3314180538e194bfcc [diff] |
Fix for date serialization problem in JsonRequestProcessor. Datanucleus returns custom subtypes of java.util.Date from the datastore, which causes Dates to be serialized as english strings. Review at http://gwt-code-reviews.appspot.com/790801 git-svn-id: https://google-web-toolkit.googlecode.com/svn/trunk@8619 8db76d5a-ed1c-0410-87a9-c151d255dfc7
diff --git a/user/src/com/google/gwt/requestfactory/server/JsonRequestProcessor.java b/user/src/com/google/gwt/requestfactory/server/JsonRequestProcessor.java index 564a3d1..a0974cf 100644 --- a/user/src/com/google/gwt/requestfactory/server/JsonRequestProcessor.java +++ b/user/src/com/google/gwt/requestfactory/server/JsonRequestProcessor.java
@@ -320,7 +320,7 @@ if (Boolean.class == type) { return value; } - if (Date.class == type) { + if (Date.class.isAssignableFrom(type)) { return String.valueOf(((Date) value).getTime()); } if (Enum.class.isAssignableFrom(type)) {