mirror of
https://github.com/samsonjs/strftime.git
synced 2026-03-25 09:05:48 +00:00
Improve detection of timezone name
Timezone name can contain contain spaces (ex. "GTB Daylight Time" or "Pacific Daylight Time") this is why we should use [\w\s+] instead of \w.
This commit is contained in:
parent
f3bed1d081
commit
9ea642274c
1 changed files with 1 additions and 1 deletions
|
|
@ -260,7 +260,7 @@
|
|||
return "GMT";
|
||||
}
|
||||
else {
|
||||
var tzString = d.toString().match(/\((\w+)\)/);
|
||||
var tzString = d.toString().match(/\(([\w\s]+)\)/);
|
||||
return tzString && tzString[1] || '';
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue