Skip to content

Commit

Permalink
refactor(types): Section implements 'WithElements' (#959)
Browse files Browse the repository at this point in the history
Co-authored-by: Xavier Coulon <[email protected]>
  • Loading branch information
rxt1077 and xcoulon authored Mar 4, 2022
1 parent 8e3016b commit 6ddd7e6
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions pkg/types/types.go
Original file line number Diff line number Diff line change
Expand Up @@ -2400,6 +2400,19 @@ func (s *Section) GetID() (string, error) {
return id, err
}

var _ WithElements = &Section{}

// GetElements returns this Section's elements
func (s *Section) GetElements() []interface{} {
return s.Elements
}

// SetElements sets this Sections's elements
func (s *Section) SetElements(elements []interface{}) error {
s.Elements = elements
return nil
}

var _ WithTitle = &Section{}

// GetTitle returns this section's title
Expand Down

0 comments on commit 6ddd7e6

Please sign in to comment.