MCPcopy Create free account
hub / github.com/Semporia/Scripts / timeFormat

Function timeFormat

jd_fruit.js:1249–1257  ·  view source on GitHub ↗
(time)

Source from the content-addressed store, hash-verified

1247}
1248
1249function timeFormat(time) {
1250 let date;
1251 if (time) {
1252 date = new Date(time)
1253 } else {
1254 date = new Date();
1255 }
1256 return date.getFullYear() + '-' + ((date.getMonth() + 1) >= 10 ? (date.getMonth() + 1) : '0' + (date.getMonth() + 1)) + '-' + (date.getDate() >= 10 ? date.getDate() : '0' + date.getDate());
1257}
1258function readShareCode() {
1259 return new Promise(async resolve => {
1260 $.get({url: `http://www.helpu.cf/jdcodes/getcode.php?type=farm&num=${randomCount}`, timeout: 10000,}, (err, resp, data) => {

Callers 2

predictionFruitFunction · 0.70
masterHelpShareFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected