Better parameter order for ReplaceCallback

This commit is contained in:
tj 2010-03-12 21:55:56 +01:00
parent 2c7ddd7719
commit a557416dcf

View File

@ -21,7 +21,7 @@ func (irc *IRCConnection) AddCallback(eventcode string, callback func(*IRCEvent)
} }
} }
func (irc *IRCConnection) ReplaceCallback(i uint8, eventcode string, callback func(*IRCEvent)) { func (irc *IRCConnection) ReplaceCallback(eventcode string, i uint8, callback func(*IRCEvent)) {
eventcode = strings.ToUpper(eventcode) eventcode = strings.ToUpper(eventcode)
if event, ok := irc.events[eventcode]; ok { if event, ok := irc.events[eventcode]; ok {
event[i] = callback event[i] = callback