Skip to content

Commit

Permalink
delete unneeded code in types.go
Browse files Browse the repository at this point in the history
  • Loading branch information
SimonMen65 committed Jan 27, 2021
1 parent 3680d84 commit e779461
Showing 1 changed file with 0 additions and 17 deletions.
17 changes: 0 additions & 17 deletions data/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -125,21 +125,6 @@ func (t *Targets) TargetAddKey(key *Key) bool {
return changed
}

//DelegationAddKey check existence of a key,
//Add it to Delegation's key filed if not exist
/*
func (d *Delegation) DelegationAddKey(key *Key) bool {
changed := false
for _, id := range key.IDs() {
if _, ok := d.Keys[id]; !ok {
changed = true
d.Keys[id] = key
}
}
return changed
}
*/

// UniqueKeys returns the unique keys for each associated role.
// We might have multiple key IDs that correspond to the same key.
func (r Root) UniqueKeys() map[string][]*Key {
Expand Down Expand Up @@ -266,7 +251,6 @@ type Targets struct {
Targets TargetFiles `json:"targets"`
Keys map[string]*Key `json:"keys"`
Roles map[string]*Role `json:"roles"`
//Delegations map[string]*Delegation `json:"delegations"`
}


Expand All @@ -278,7 +262,6 @@ func NewTargets() *Targets {
Targets: make(TargetFiles),
Keys: make(map[string]*Key),
Roles: make(map[string]*Role),
//Delegations: make(map[string]*Delegation),
}
}

Expand Down

0 comments on commit e779461

Please sign in to comment.