Give DateTime scalars valid names to pass validation

This commit is contained in:
Jacob Haslehurst 2017-10-11 22:12:11 +11:00 committed by theduke
parent 39623fe3ec
commit 62d5e28a97

View file

@ -20,7 +20,7 @@ use ::Value;
#[doc(hidden)]
pub static RFC3339_FORMAT: &'static str = "%Y-%m-%dT%H:%M:%S%z";
graphql_scalar!(DateTime<FixedOffset> {
graphql_scalar!(DateTime<FixedOffset> as "DateTimeFixedOffset" {
description: "DateTime"
resolve(&self) -> Value {
@ -33,7 +33,7 @@ graphql_scalar!(DateTime<FixedOffset> {
}
});
graphql_scalar!(DateTime<Utc> {
graphql_scalar!(DateTime<Utc> as "DateTimeUtc" {
description: "DateTime"
resolve(&self) -> Value {