优化代码

This commit is contained in:
wuxw 2024-04-25 11:01:15 +08:00
parent 8913abe883
commit 3450506f04

View File

@ -103,10 +103,14 @@
let _date = new Date();
let _curHours = _date.getHours();
_that.curSecHours = this.secHours[0];
let _break =false;
this.secHours.forEach(_hours => {
if(_break){
return;
}
if (_hours.hours >= _curHours) {
_that.curSecHours = _hours;
return;
_break = true
}
})