diff options
| author | Philip Roberts | 2013-01-30 10:50:34 +0100 |
|---|---|---|
| committer | Igor Minar | 2013-02-07 01:32:04 -0800 |
| commit | b001c8ece5472626bf49cf82753e8ac1aafd2513 (patch) | |
| tree | 6442b82191aae96039d6648c79f84ba16aa46559 /src/ng/http.js | |
| parent | bec4435945d9a18eb6650caaca022da00fd7a1d4 (diff) | |
| download | angular.js-b001c8ece5472626bf49cf82753e8ac1aafd2513.tar.bz2 | |
fix(date): invert timezone sign and always display sign
This commit fixes #1261 and #1532. This covers
two separate issues:
- Positive timezones were being formatted without
a leading `+` resulting in a formatting string
like: "HH:MM:ssZ" giving "12:13:141000" instead
of "12:13:14+1000". Fixed by checking if timezone
is > 0 and adding a leading "+".
- Timezone output signs were inverted.
mock.TzDate expects the timezone _offset_ as it's
first argument, _not_ the timezone. This means
that a mock.TzDate with a positive offset should
result in a date string with a negative timezone,
and vice-versa.
Closes #1261, #1532
Diffstat (limited to 'src/ng/http.js')
0 files changed, 0 insertions, 0 deletions
