Skip to content
This repository has been archived by the owner on Oct 17, 2024. It is now read-only.

Commit

Permalink
feat(generate)!: Exclude Map and List from pointer
Browse files Browse the repository at this point in the history
BREAKING CHANGE: Goformation no longer generates pointer types for
Lists, Maps and interface{} types.
  • Loading branch information
daemonl authored and rubenfonseca committed Sep 29, 2022
1 parent 4c6aafe commit aec3913
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions generate/property.go
Original file line number Diff line number Diff line change
Expand Up @@ -271,6 +271,9 @@ func (p Property) UsePointer() bool {
if p.IsPolymorphic() || p.IsCustomType() {
return true
}
if p.IsList() || p.IsMap() {
return false
}
if !p.Required && !p.IsGeneric() {
return true
}
Expand Down

0 comments on commit aec3913

Please sign in to comment.