discord_bot/util/convertDateToISOString.js
SileNce5k a1986c12a2
Add convertDateToISOString.js
Also make getCreationDate.js and getJoinDate.js use this function
2021-06-28 17:56:16 +02:00

3 lines
No EOL
232 B
JavaScript

module.exports = function (date){
return date.getUTCFullYear() + '-' + ('0' + (date.getUTCMonth()+1)).slice(-2) + '-' + ('0' + date.getUTCDate()).slice(-2)+" "+date.getUTCHours()+":"+date.getUTCMinutes()+":"+date.getUTCSeconds();
}