// DeleteBuild removes any record of the build by removing it and all of the tasks that // are a part of it from the database. func DeleteBuild(id string) error { err := RemoveAllTasks(bson.M{TaskBuildIdKey: id}) if err != nil && err != mgo.ErrNotFound { return err } return build.Remove(id) }
// DeleteBuild removes any record of the build by removing it and all of the tasks that // are a part of it from the database. func DeleteBuild(id string) error { err := task.RemoveAllWithBuild(id) if err != nil && err != mgo.ErrNotFound { return err } return build.Remove(id) }