浏览代码

Switch from time.ISOWeak()

develoopeer 6 月之前
父节点
当前提交
2012983025
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      internal/glance/widget-calendar.go

+ 1 - 1
internal/glance/widget-calendar.go

@@ -60,7 +60,7 @@ type calendar struct {
 // TODO: very inflexible, refactor to allow more customizability
 // TODO: allow changing between showing the previous and next week and the entire month
 func newCalendar(now time.Time, startSunday bool, icsurl string) *calendar {
-	year, week := now.ISOWeek()
+	year, week := now.Year(), int(now.Weekday())
 	weekday := now.Weekday()
 	if !startSunday {
 		weekday = (weekday + 6) % 7 // Shift Monday to 0