This commit is contained in:
Dvorinka
2025-06-20 09:42:46 +02:00
parent c18592e194
commit d5c7de54b1
+2 -2
View File
@@ -230,7 +230,7 @@ func trackVisit(w http.ResponseWriter, r *http.Request) {
}
// Reset weekly visits on Monday
if stats.LastUpdated.Weekday() != time.Now().Weekday() {
if time.Now().Weekday() == time.Monday && stats.LastUpdated.Weekday() != time.Monday {
stats.WeeklyVisits = 1
}
@@ -248,7 +248,7 @@ func trackVisit(w http.ResponseWriter, r *http.Request) {
}
w.WriteHeader(http.StatusOK)
}
// Helper function to extract OS from User-Agent
func getOSFromUserAgent(userAgent string) string {