Merge pull request #135 from kortschak/mongo

Quieten go vet in mongo
This commit is contained in:
Barak Michener 2014-08-21 13:27:27 -04:00
commit cce0f88803
2 changed files with 11 additions and 11 deletions

View file

@ -130,9 +130,9 @@ func (it *Iterator) Clone() graph.Iterator {
func (it *Iterator) Next() bool { func (it *Iterator) Next() bool {
var result struct { var result struct {
Id string "_id" Id string `bson:"_id"`
Added []int64 "Added" Added []int64 `bson:"Added"`
Deleted []int64 "Deleted" Deleted []int64 `bson:"Deleted"`
} }
found := it.iter.Next(&result) found := it.iter.Next(&result)
if !found { if !found {

View file

@ -121,15 +121,15 @@ func (qs *TripleStore) convertStringToByteHash(s string) string {
} }
type MongoNode struct { type MongoNode struct {
Id string "_id" Id string `bson:"_id"`
Name string "Name" Name string `bson:"Name"`
Size int "Size" Size int `bson:"Size"`
} }
type MongoLogEntry struct { type MongoLogEntry struct {
LogID int64 "LogID" LogID int64 `bson:"LogID"`
Action string "Action" Action string `bson:"Action"`
Key string "Key" Key string `bson:"Key"`
Timestamp int64 Timestamp int64
} }
@ -175,8 +175,8 @@ func (qs *TripleStore) updateQuad(q quad.Quad, id int64, proc graph.Procedure) e
func (qs *TripleStore) checkValid(key string) bool { func (qs *TripleStore) checkValid(key string) bool {
var indexEntry struct { var indexEntry struct {
Added []int64 "Added" Added []int64 `bson:"Added"`
Deleted []int64 "Deleted" Deleted []int64 `bson:"Deleted"`
} }
err := qs.db.C("quads").FindId(key).One(&indexEntry) err := qs.db.C("quads").FindId(key).One(&indexEntry)
if err == mgo.ErrNotFound { if err == mgo.ErrNotFound {