This commit is contained in:
Ryan Cavicchioni 2022-09-04 22:36:14 -05:00
parent 9b33684d60
commit 4a024e98f2
Signed by: ryanc
GPG Key ID: 877EEDAF9245103D
7 changed files with 7 additions and 21 deletions

View File

@ -21,9 +21,7 @@ func (c *Coin) Flip() bool {
} }
func NewCoinHandler(s string) *CoinHandler { func NewCoinHandler(s string) *CoinHandler {
h := new(CoinHandler) return &CoinHandler{Name: s}
h.Name = s
return h
} }
func (h *CoinHandler) SetConfig(config bot.Config) { func (h *CoinHandler) SetConfig(config bot.Config) {

View File

@ -85,9 +85,7 @@ func (r *Roll) RollDice() {
} }
func NewRollHandler(s string) *RollHandler { func NewRollHandler(s string) *RollHandler {
h := new(RollHandler) return &RollHandler{Name: s}
h.Name = s
return h
} }
func (h *RollHandler) SetConfig(config bot.Config) { func (h *RollHandler) SetConfig(config bot.Config) {

View File

@ -15,9 +15,7 @@ type (
) )
func NewPingHandler(s string) *PingHandler { func NewPingHandler(s string) *PingHandler {
h := new(PingHandler) return &PingHandler{Name: s}
h.Name = s
return h
} }
func (h *PingHandler) SetConfig(config bot.Config) { func (h *PingHandler) SetConfig(config bot.Config) {

View File

@ -75,9 +75,7 @@ func (g *Gun) IsEmpty() bool {
} }
func NewRouletteHandler(s string) *RouletteHandler { func NewRouletteHandler(s string) *RouletteHandler {
h := new(RouletteHandler) return &RouletteHandler{Name: s}
h.Name = s
return h
} }
func (h *RouletteHandler) SetConfig(config bot.Config) { func (h *RouletteHandler) SetConfig(config bot.Config) {

View File

@ -18,9 +18,7 @@ type (
) )
func NewTimeHandler(s string) *TimeHandler { func NewTimeHandler(s string) *TimeHandler {
h := new(TimeHandler) return &TimeHandler{Name: s}
h.Name = s
return h
} }
func (h *TimeHandler) SetConfig(config bot.Config) { func (h *TimeHandler) SetConfig(config bot.Config) {

View File

@ -21,9 +21,7 @@ type (
) )
func NewVersionHandler(s string) *VersionHandler { func NewVersionHandler(s string) *VersionHandler {
h := new(VersionHandler) return &VersionHandler{Name: s}
h.Name = s
return h
} }
func (h *VersionHandler) SetConfig(config bot.Config) { func (h *VersionHandler) SetConfig(config bot.Config) {

View File

@ -17,9 +17,7 @@ type WeatherHandler struct {
} }
func NewWeatherHandler(s string) *WeatherHandler { func NewWeatherHandler(s string) *WeatherHandler {
h := new(WeatherHandler) return &WeatherHandler{Name: s}
h.Name = s
return h
} }
func (h *WeatherHandler) SetConfig(config bot.Config) { func (h *WeatherHandler) SetConfig(config bot.Config) {