* func saveBlock(c *mgo.Collection, block BlockModel) { //first, check if the item already exists result := BlockModel{} err := c.Find(bson.M{"hash": block.Hash}).One(&result) if err != nil { //item not found, so let's add a new entry err = c.Insert(block) check(err) } else { err = c.Up
()
source not stored for this graph (policy: none)