diff options
| author | Jeff Carr <[email protected]> | 2024-11-29 21:51:30 -0600 |
|---|---|---|
| committer | Jeff Carr <[email protected]> | 2024-11-29 21:51:30 -0600 |
| commit | 3d260a0219841f4835d6a0d0e370bde483f35d08 (patch) | |
| tree | b6e3b09004109581d618613d9c72d2049656074b /goDep.helpers.go | |
| parent | 4a79cccffd6cd20e42271eada567c4b8c0edc2f4 (diff) | |
updates for autogenpb
Diffstat (limited to 'goDep.helpers.go')
| -rw-r--r-- | goDep.helpers.go | 26 |
1 files changed, 1 insertions, 25 deletions
diff --git a/goDep.helpers.go b/goDep.helpers.go index 470d750..0af28be 100644 --- a/goDep.helpers.go +++ b/goDep.helpers.go @@ -8,35 +8,11 @@ import ( ) func (repo *Repo) DeleteGoDepByHash(hash string) *GoDep { - /* - refslock.Lock() - defer refslock.Unlock() - - for i, _ := range repo.GoDeps { - if repo.GoDeps[i].Hash == hash { - repo.GoDeps[i] = repo.GoDeps[len(repo.GoDeps)-1] - repo.GoDeps = repo.GoDeps[:len(repo.GoDeps)-1] - return nil - } - } - */ - return nil + return repo.GoDeps.DeleteByHash(hash) } // enforces no duplicate package names func (repo *Repo) AppendGoDep(newP *GoDep) bool { - /* - refslock.Lock() - defer refslock.Unlock() - - for _, p := range repo.GoDeps { - if p.GoPath == newP.GoPath { - return false - } - } - - repo.GoDeps = append(repo.GoDeps, newP) - */ return repo.GoDeps.AppendUniqueGoPath(newP) } |
