mirror of
https://github.com/Crocmagnon/display-epaper.git
synced 2024-11-21 13:38:03 +01:00
fix quote for last day of month
This commit is contained in:
parent
f9c3153db1
commit
40a974cc6f
1 changed files with 12 additions and 12 deletions
|
@ -5,29 +5,29 @@ import "time"
|
||||||
func GetQuote(date time.Time) string {
|
func GetQuote(date time.Time) string {
|
||||||
switch date.Month() {
|
switch date.Month() {
|
||||||
case time.January:
|
case time.January:
|
||||||
return january[date.Day()]
|
return january[date.Day()-1]
|
||||||
case time.February:
|
case time.February:
|
||||||
return february[date.Day()]
|
return february[date.Day()-1]
|
||||||
case time.March:
|
case time.March:
|
||||||
return march[date.Day()]
|
return march[date.Day()-1]
|
||||||
case time.April:
|
case time.April:
|
||||||
return april[date.Day()]
|
return april[date.Day()-1]
|
||||||
case time.May:
|
case time.May:
|
||||||
return may[date.Day()]
|
return may[date.Day()-1]
|
||||||
case time.June:
|
case time.June:
|
||||||
return june[date.Day()]
|
return june[date.Day()-1]
|
||||||
case time.July:
|
case time.July:
|
||||||
return july[date.Day()]
|
return july[date.Day()-1]
|
||||||
case time.August:
|
case time.August:
|
||||||
return august[date.Day()]
|
return august[date.Day()-1]
|
||||||
case time.September:
|
case time.September:
|
||||||
return september[date.Day()]
|
return september[date.Day()-1]
|
||||||
case time.October:
|
case time.October:
|
||||||
return october[date.Day()]
|
return october[date.Day()-1]
|
||||||
case time.November:
|
case time.November:
|
||||||
return november[date.Day()]
|
return november[date.Day()-1]
|
||||||
case time.December:
|
case time.December:
|
||||||
return december[date.Day()]
|
return december[date.Day()-1]
|
||||||
}
|
}
|
||||||
return ""
|
return ""
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue