summaryrefslogtreecommitdiff
path: root/internal/schedule
diff options
context:
space:
mode:
authorPaul Buetow <paul@buetow.org>2024-12-11 22:07:51 +0200
committerPaul Buetow <paul@buetow.org>2024-12-11 22:07:51 +0200
commit1dca76e728a70b70ee8001c87407acf962e731cd (patch)
tree4636d5b8769595de135bca8977b951d0a570da48 /internal/schedule
parenta5529938536f7a530f0c55e5a82b16a4c80af5b4 (diff)
refactor a bit again
Diffstat (limited to 'internal/schedule')
-rw-r--r--internal/schedule/schedule.go2
-rw-r--r--internal/schedule/stats.go5
2 files changed, 3 insertions, 4 deletions
diff --git a/internal/schedule/schedule.go b/internal/schedule/schedule.go
index 2985da2..9b31f88 100644
--- a/internal/schedule/schedule.go
+++ b/internal/schedule/schedule.go
@@ -77,7 +77,7 @@ func selectRandomEntry(dir, tag string) (entry.Entry, error) {
}
en, err := entry.New(filepath.Join(dir, file.Name()))
if err != nil {
- _, _ = colour.Infoln(err)
+ colour.Infoln(err)
return entry.Zero, false
}
return en, en.State == entry.Queued
diff --git a/internal/schedule/stats.go b/internal/schedule/stats.go
index b4f8153..a9d5ba4 100644
--- a/internal/schedule/stats.go
+++ b/internal/schedule/stats.go
@@ -81,13 +81,12 @@ func (s stats) targetHit(pauseDays, maxQueuedDays int) bool {
pauseDays--
}
if s.postsPerDay >= s.postsPerDayTarget {
- _, _ = colour.Infoln("Posts per day target hit")
+ colour.Infoln("Posts per day target hit")
return true
}
if s.lastPostDaysAgo <= float64(pauseDays) {
- _, _ = colour.Infoln("Need to wait a bit longer as last post isn't", pauseDays, "days ago yet")
+ colour.Infoln("Need to wait a bit longer as last post isn't", pauseDays, "days ago yet")
return true
-
}
return false
}