Skip to content

Commit

Permalink
Merge pull request #77 from splitsh/dead-code
Browse files Browse the repository at this point in the history
Remove dead code
  • Loading branch information
fabpot committed Mar 7, 2024
2 parents 4aa9676 + e6d25ea commit 2e82f4a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
7 changes: 1 addition & 6 deletions splitter/cache.go
Expand Up @@ -120,13 +120,8 @@ func (c *cache) get(rev *git.Oid) *git.Oid {
return oid
}

func (c *cache) set(rev, newrev *git.Oid, created bool) {
func (c *cache) set(rev, newrev *git.Oid) {
c.data[string(rev[0:20])] = newrev[0:20]
postfix := "/newest"
if created {
postfix = "/oldest"
}
c.data[string(append(newrev[0:20], []byte(postfix)...))] = rev[0:20]
}

func (c *cache) gets(commits []*git.Oid) []*git.Oid {
Expand Down
2 changes: 1 addition & 1 deletion splitter/state.go
Expand Up @@ -239,7 +239,7 @@ func (s *state) splitRev(rev *git.Commit) (*git.Oid, error) {
s.result.incCreated()
}

s.cache.set(rev.Id(), newrev, created)
s.cache.set(rev.Id(), newrev)

return newrev, nil
}
Expand Down

0 comments on commit 2e82f4a

Please sign in to comment.