3
0
mirror of https://github.com/ergochat/ergo.git synced 2024-11-10 22:19:31 +01:00

simplify new channel insert

This commit is contained in:
Jeremy Latt 2014-02-25 13:12:11 -08:00
parent 02abeeb164
commit e409bcec99
2 changed files with 2 additions and 6 deletions

View File

@ -35,11 +35,7 @@ func NewChannel(s *Server, name string) *Channel {
} }
s.channels[name] = channel s.channels[name] = channel
s.db.Exec(`INSERT INTO channel s.db.Exec(`INSERT INTO channel (name) VALUES (?)`, channel.name)
(name, flags, key, topic, user_limit)
VALUES (?, ?, ?, ?, ?)`,
channel.name, channel.flags.String(), channel.key, channel.topic,
channel.userLimit)
return channel return channel
} }

View File

@ -209,7 +209,7 @@ const (
LocalOperator UserMode = 'O' LocalOperator UserMode = 'O'
Operator UserMode = 'o' Operator UserMode = 'o'
Restricted UserMode = 'r' Restricted UserMode = 'r'
ServerNotice UserMode = 's' ServerNotice UserMode = 's' // deprecated
WallOps UserMode = 'w' WallOps UserMode = 'w'
Anonymous ChannelMode = 'a' // flag Anonymous ChannelMode = 'a' // flag