summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjakefeasel <jfeasel@gmail.com>2013-03-11 21:54:46 -0700
committerjakefeasel <jfeasel@gmail.com>2013-03-11 21:54:46 -0700
commitc2776d576bd6dc4415d3f8497f68728a7956bdd3 (patch)
tree714a456a1a101c256daa663a70e8b1cf2c512e3b
parent0c6d630c4e4de4ce25ac7e470054ba1b23663ca9 (diff)
downloadDDLBuilder-c2776d576bd6dc4415d3f8497f68728a7956bdd3.zip
DDLBuilder-c2776d576bd6dc4415d3f8497f68728a7956bdd3.tar.gz
DDLBuilder-c2776d576bd6dc4415d3f8497f68728a7956bdd3.tar.bz2
https://github.com/jakefeasel/DDLBuilder/issues/2
Firefox bug with certain date inputs causing JS error to be thrown
-rw-r--r--ddl_builder/ddl_builder.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/ddl_builder/ddl_builder.js b/ddl_builder/ddl_builder.js
index 4bf9da3..6be03ac 100644
--- a/ddl_builder/ddl_builder.js
+++ b/ddl_builder/ddl_builder.js
@@ -310,7 +310,7 @@ define(
{
// if we haven't previously decided that this is a character field, and it can be cast as a date, then declare it a date
- if (this.definition.columns[j].type != 'charType' && !(isNaN(Date.parse(value)) || value.match(brokenDateChecker)) )
+ if (this.definition.columns[j].type != 'charType' && !(isNaN(Date.parse("UTC:" + value)) || value.match(brokenDateChecker)) )
this.definition.columns[j].type = "dateType";
else
this.definition.columns[j].type = "charType";