diff options
Diffstat (limited to 'node_modules/locutus/php/datetime/date_parse.js.map')
-rw-r--r-- | node_modules/locutus/php/datetime/date_parse.js.map | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/node_modules/locutus/php/datetime/date_parse.js.map b/node_modules/locutus/php/datetime/date_parse.js.map deleted file mode 100644 index bf66a26..0000000 --- a/node_modules/locutus/php/datetime/date_parse.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["../../../src/php/datetime/date_parse.js"],"names":["module","exports","date_parse","date","strtotime","require","ts","e","dt","Date","retObj","year","getFullYear","month","getMonth","day","getDate","hour","getHours","minute","getMinutes","second","getSeconds","fraction","parseFloat","getMilliseconds","is_localtime","getTimezoneOffset"],"mappings":";;AAAAA,OAAOC,OAAP,GAAiB,SAASC,UAAT,CAAqBC,IAArB,EAA2B;AAAE;AAC5C;AACA;AACA;AACA;;AAEA,MAAIC,YAAYC,QAAQ,uBAAR,CAAhB;AACA,MAAIC,EAAJ;;AAEA,MAAI;AACFA,SAAKF,UAAUD,IAAV,CAAL;AACD,GAFD,CAEE,OAAOI,CAAP,EAAU;AACVD,SAAK,KAAL;AACD;;AAED,MAAI,CAACA,EAAL,EAAS;AACP,WAAO,KAAP;AACD;;AAED,MAAIE,KAAK,IAAIC,IAAJ,CAASH,KAAK,IAAd,CAAT;;AAEA,MAAII,SAAS,EAAb;;AAEAA,SAAOC,IAAP,GAAcH,GAAGI,WAAH,EAAd;AACAF,SAAOG,KAAP,GAAeL,GAAGM,QAAH,KAAgB,CAA/B;AACAJ,SAAOK,GAAP,GAAaP,GAAGQ,OAAH,EAAb;AACAN,SAAOO,IAAP,GAAcT,GAAGU,QAAH,EAAd;AACAR,SAAOS,MAAP,GAAgBX,GAAGY,UAAH,EAAhB;AACAV,SAAOW,MAAP,GAAgBb,GAAGc,UAAH,EAAhB;AACAZ,SAAOa,QAAP,GAAkBC,WAAW,OAAOhB,GAAGiB,eAAH,EAAlB,CAAlB;AACAf,SAAOgB,YAAP,GAAsBlB,GAAGmB,iBAAH,OAA2B,CAAjD;;AAEA,SAAOjB,MAAP;AACD,CAjCD","file":"date_parse.js","sourcesContent":["module.exports = function date_parse (date) { // eslint-disable-line camelcase\n // discuss at: http://locutus.io/php/date_parse/\n // original by: Brett Zamir (http://brett-zamir.me)\n // example 1: date_parse('2006-12-12 10:00:00')\n // returns 1: {year : 2006, month: 12, day: 12, hour: 10, minute: 0, second: 0, fraction: 0, is_localtime: false}\n\n var strtotime = require('../datetime/strtotime')\n var ts\n\n try {\n ts = strtotime(date)\n } catch (e) {\n ts = false\n }\n\n if (!ts) {\n return false\n }\n\n var dt = new Date(ts * 1000)\n\n var retObj = {}\n\n retObj.year = dt.getFullYear()\n retObj.month = dt.getMonth() + 1\n retObj.day = dt.getDate()\n retObj.hour = dt.getHours()\n retObj.minute = dt.getMinutes()\n retObj.second = dt.getSeconds()\n retObj.fraction = parseFloat('0.' + dt.getMilliseconds())\n retObj.is_localtime = dt.getTimezoneOffset() !== 0\n\n return retObj\n}\n"]}
\ No newline at end of file |