Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions VERSIONS.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# Version 1.7.3
* Fixed block page showing cycle rollover time instead of manual lockdown end time.

# Version 1.7.2 (04 Jan 2026)
* Added option to specify minimum block time.
* Added option to block only first accessed page of block set.
Expand Down
13 changes: 10 additions & 3 deletions background.js
Original file line number Diff line number Diff line change
Expand Up @@ -1283,8 +1283,15 @@ function getUnblockTime(set) {
} else if (!timePeriods && timeLimit) {
// Case 2: after time limit (no time periods)

// Return end time for current time limit period
unblockTime = new Date(timedata[2] * 1000 + limitPeriod * 1000);
// Determine whether time limit has actually been exceeded
let secsRollover = rollover ? timedata[5] : 0;
let afterTimeLimit = (timedata[2] == periodStart)
&& (timedata[3] >= secsRollover + (limitMins * 60));

if (afterTimeLimit) {
// Return end time for current time limit period
unblockTime = new Date(timedata[2] * 1000 + limitPeriod * 1000);
}
} else if (timePeriods && timeLimit) {
if (conjMode) {
// Case 3: within time periods AND after time limit
Expand Down Expand Up @@ -1330,7 +1337,7 @@ function getUnblockTime(set) {
}
}

if (!unblockTime) {
if (!unblockTime && afterTimeLimit) {
// Return end time for current time limit period
unblockTime = new Date(timedata[2] * 1000 + limitPeriod * 1000);
}
Expand Down