Fully Initialize on New
This commit is contained in:
parent
cf2312525d
commit
8a9e6c2bec
@ -19,7 +19,7 @@ type TimerList struct {
|
||||
}
|
||||
|
||||
// NewTimerList creates a new empty TimerList.
|
||||
func NewTimerList() *TimerList { return &TimerList{} }
|
||||
func NewTimerList() *TimerList { return &TimerList{Timers: []*Timer{}} }
|
||||
func (timerlist *TimerList) Size() int { return len(timerlist.Timers) }
|
||||
func (timerlist *TimerList) GetTimerSlice() []*Timer { return timerlist.Timers }
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user