summaryrefslogtreecommitdiff
path: root/server/channel
diff options
context:
space:
mode:
Diffstat (limited to 'server/channel')
-rw-r--r--server/channel/channel.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/server/channel/channel.go b/server/channel/channel.go
index 9ec0b41..9984b7b 100644
--- a/server/channel/channel.go
+++ b/server/channel/channel.go
@@ -186,11 +186,11 @@ func (c *Channel) Put(m proto.Object, From *session.Session) proto.Object {
channel, _ := history.CreateBucketIfNotExists([]byte(c.id))
ids, _ := channel.CreateBucketIfNotExists([]byte("ids"))
- index, err := channel.NextSequence()
+ key := []byte(strconv.Itoa(int(channel.Sequence())))
+ _, err := channel.NextSequence()
if err != nil {
return err
}
- key := []byte(strconv.Itoa(int(index)))
var buf bytes.Buffer
writer := bufio.NewWriter(&buf)