Skip to content

Commit

Permalink
From bytes.Add() which is deprecated; to append()
Browse files Browse the repository at this point in the history
  • Loading branch information
phillyqueso committed Dec 9, 2010
1 parent b56fb29 commit bd2d3c8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions mongo/bson.go
Expand Up @@ -144,7 +144,7 @@ func (self *_Object) Bytes() []byte {
l := buf.Len() + 4 l := buf.Len() + 4
w32 := make([]byte, _WORD32) w32 := make([]byte, _WORD32)
pack.PutUint32(w32, uint32(l)) pack.PutUint32(w32, uint32(l))
return bytes.Add(w32, buf.Bytes()) return append(w32, buf.Bytes()...)
} }


var EmptyObject BSON = &_Object{map[string]BSON{}, _Null{}} var EmptyObject BSON = &_Object{map[string]BSON{}, _Null{}}
Expand Down Expand Up @@ -182,7 +182,7 @@ func (self *_Array) Bytes() []byte {
l := buf.Len() + 4 l := buf.Len() + 4
w32 := make([]byte, _WORD32) w32 := make([]byte, _WORD32)
pack.PutUint32(w32, uint32(l)) pack.PutUint32(w32, uint32(l))
return bytes.Add(w32, buf.Bytes()) return append(w32, buf.Bytes()...)
} }


type _OID struct { type _OID struct {
Expand Down

0 comments on commit bd2d3c8

Please sign in to comment.