MCPcopy Create free account
hub / github.com/dajie111/nodeseek-userscript / becomeMaster

Method becomeMaster

Clockin.js:64–71  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

62
63 // 成为主窗口
64 becomeMaster() {
65 this.isMaster = true;
66 localStorage.setItem(STORAGE_KEYS.masterWindow, this.windowId);
67 localStorage.setItem(STORAGE_KEYS.lastHeartbeat, Date.now().toString());
68
69 // 设置下一个整点签到
70 this.scheduleNextHourlySign();
71 }
72
73 // 心跳机制
74 startHeartbeat() {

Callers 2

electMasterMethod · 0.95
checkMasterStatusMethod · 0.95

Calls 1

Tested by

no test coverage detected