Not sure if it was your intention, but your weekly update case will reset every time there is a manual update. I avoid time.After for recurring tasks in a select loop for this reason.
time.Ticker is great if you want to repeat the task at approximately the same interval. time.Timer is what I use when I want the task to repeat a certain time after the previous task has finished. You can also conveniently use timer.Reset(0) to trigger an immediate tick.
The funny thing is that I knew it, but wrote `for v := range array` anyway at least a few times! My point is, it's not very intuitive. Thankfully, the compiler catches that, unless it's `[]int`.
The idea is it's `for k := range object` to iterate over the keys, and `for k, v := range object` to iterate over the keys and values, whether the object is a slice, array, map or string. The only exceptional case is a channel, which has no indices/keys.
> "Slicing past the end of array results in a runtime panic. Ignoring out of bound indices is more convenient (and consistent with how other languages handle this)."
time.Ticker is great if you want to repeat the task at approximately the same interval. time.Timer is what I use when I want the task to repeat a certain time after the previous task has finished. You can also conveniently use timer.Reset(0) to trigger an immediate tick.