Skip to content

Commit f2b39ca

Browse files
authored
Merge pull request #684 from testwill/slice
chore: slice loop replace
2 parents 4ebf270 + 1154997 commit f2b39ca

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

schema.go

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -92,10 +92,8 @@ func NewSchema(config SchemaConfig) (Schema, error) {
9292
initialTypes = append(initialTypes, SchemaType)
9393
}
9494

95-
for _, ttype := range config.Types {
96-
// assume that user will never add a nil object to config
97-
initialTypes = append(initialTypes, ttype)
98-
}
95+
// assume that user will never add a nil object to config
96+
initialTypes = append(initialTypes, config.Types...)
9997

10098
for _, ttype := range initialTypes {
10199
if ttype.Error() != nil {

0 commit comments

Comments
 (0)