From 5f466137ad6ac596600e3ff53c9b786815398445 Mon Sep 17 00:00:00 2001 From: Florian Dold Date: Sat, 27 May 2017 17:36:13 +0200 Subject: node_modules, clean up package.json --- node_modules/to-iso-string/index.js | 40 ------------------------------------- 1 file changed, 40 deletions(-) delete mode 100644 node_modules/to-iso-string/index.js (limited to 'node_modules/to-iso-string/index.js') diff --git a/node_modules/to-iso-string/index.js b/node_modules/to-iso-string/index.js deleted file mode 100644 index 4675691f1..000000000 --- a/node_modules/to-iso-string/index.js +++ /dev/null @@ -1,40 +0,0 @@ - -/** - * Expose `toIsoString`. - */ - -module.exports = toIsoString; - - -/** - * Turn a `date` into an ISO string. - * - * https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString - * - * @param {Date} date - * @return {String} - */ - -function toIsoString (date) { - return date.getUTCFullYear() - + '-' + pad(date.getUTCMonth() + 1) - + '-' + pad(date.getUTCDate()) - + 'T' + pad(date.getUTCHours()) - + ':' + pad(date.getUTCMinutes()) - + ':' + pad(date.getUTCSeconds()) - + '.' + String((date.getUTCMilliseconds()/1000).toFixed(3)).slice(2, 5) - + 'Z'; -} - - -/** - * Pad a `number` with a ten's place zero. - * - * @param {Number} number - * @return {String} - */ - -function pad (number) { - var n = number.toString(); - return n.length === 1 ? '0' + n : n; -} \ No newline at end of file -- cgit v1.2.3