MCPcopy Create free account
hub / github.com/smallfawn/QLScriptPublic / isSignedToday

Method isSignedToday

wxapp/dasenlin.js:267–275  ·  view source on GitHub ↗
(signDate)

Source from the content-addressed store, hash-verified

265 }
266
267 isSignedToday(signDate) {
268 if (!signDate) return false;
269 const date = new Date(Number(signDate) || signDate);
270 if (Number.isNaN(date.getTime())) return false;
271 const y = date.getFullYear();
272 const m = String(date.getMonth() + 1).padStart(2, "0");
273 const d = String(date.getDate()).padStart(2, "0");
274 return `${y}-${m}-${d}` === todayText();
275 }
276
277 async signIn() {
278 const userSign = this.signInfo?.userSign || {};

Callers 2

getSignInfoMethod · 0.95
signInMethod · 0.95

Calls 2

getTimeMethod · 0.80
todayTextFunction · 0.70

Tested by

no test coverage detected