refactor: tidy a bit

This commit is contained in:
James Houlahan
2020-08-05 15:00:31 +02:00
parent 0d4d95360f
commit f4374a02da
3 changed files with 17 additions and 14 deletions

View File

@ -14,7 +14,7 @@ type Part struct {
children Parts
}
func (p *Part) Part(n int) (part *Part, err error) {
func (p *Part) Child(n int) (part *Part, err error) {
if len(p.children) < n {
return nil, errors.New("no such part")
}