browser-tz
Advanced tools
Comparing version 0.3.4 to 0.3.5
@@ -137,4 +137,4 @@ var moment = require("moment-timezone/moment-timezone.js") | ||
var targetDate = addNoTimezone(type, { iso: localISO }, amount) | ||
return IsoString({ iso: targetDate, timezone: date.timezone }) | ||
var iso = IsoString({ iso: targetDate, timezone: date.timezone }) | ||
return iso | ||
} | ||
@@ -141,0 +141,0 @@ |
@@ -20,3 +20,3 @@ var moment = require("moment-timezone/moment-timezone.js") | ||
var time = moment(date.iso).tz(date.timezone) | ||
// console.log("parseToMoment.time", String(time)) | ||
// console.log("parseToMoment.time", String(time), date) | ||
@@ -36,2 +36,4 @@ // moment casts "local" dates to be in the machine timezone | ||
// time.minute(isoDate.minute) | ||
// console.log("isoDate.month", isoDate.month) | ||
time.month(isoDate.month - 1) | ||
time.date(isoDate.day) | ||
@@ -38,0 +40,0 @@ |
{ | ||
"name": "browser-tz", | ||
"version": "0.3.4", | ||
"version": "0.3.5", | ||
"description": "Timezone specific manipulation of datetime strings", | ||
@@ -5,0 +5,0 @@ "keywords": [], |
@@ -245,2 +245,6 @@ var test = require("tape") | ||
assert.equal(tz.addWeek({ | ||
iso: "2013-08-25T00:00:00.000-07:00", | ||
timezone: "America/Los_Angeles" | ||
}, 1), "2013-09-01T00:00:00.000-07:00") | ||
@@ -247,0 +251,0 @@ assert.equal(tz.addWeek({ |
@@ -72,2 +72,7 @@ var test = require("tape") | ||
assert.equal(tz.IsoString({ | ||
iso: "2013-09-01T00:00:00.000", | ||
timezone: "America/Los_Angeles" | ||
}), "2013-09-01T00:00:00.000-07:00") | ||
assert.end() | ||
@@ -74,0 +79,0 @@ }) |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
49525
1044