diff options
Diffstat (limited to 'identity')
-rw-r--r-- | identity/identity.go | 1 | ||||
-rw-r--r-- | identity/identity_test.go | 4 |
2 files changed, 0 insertions, 5 deletions
diff --git a/identity/identity.go b/identity/identity.go index b002f34f0..052740675 100644 --- a/identity/identity.go +++ b/identity/identity.go @@ -26,7 +26,6 @@ func NewPathIdentity(typ, pat string) PathIdentity { type Identities map[Identity]Provider func (ids Identities) search(depth int, id Identity) Provider { - if v, found := ids[id.GetIdentity()]; found { return v } diff --git a/identity/identity_test.go b/identity/identity_test.go index c315df1e7..baf2628bb 100644 --- a/identity/identity_test.go +++ b/identity/identity_test.go @@ -33,14 +33,12 @@ func TestIdentityManager(t *testing.T) { } func BenchmarkIdentityManager(b *testing.B) { - createIds := func(num int) []Identity { ids := make([]Identity, num) for i := 0; i < num; i++ { ids[i] = testIdentity{name: fmt.Sprintf("id%d", i)} } return ids - } b.Run("Add", func(b *testing.B) { @@ -75,9 +73,7 @@ func BenchmarkIdentityManager(b *testing.B) { id := im.Search(testIdentity{name: name}) c.Assert(id.GetIdentity().Name(), qt.Equals, name) } - }) - } type testIdentity struct { |