Skip to content

Commit

Permalink
fix CreateTable with duplicate NonKeyAttributes (#88)
Browse files Browse the repository at this point in the history
  • Loading branch information
guregu committed Feb 19, 2019
1 parent d8bb6a0 commit 8764212
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions createtable.go
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,13 @@ func (ct *CreateTable) Project(index string, projection IndexProjection, include
ProjectionType: &projectionStr,
}
if projection == IncludeProjection {
attribs:
for _, attr := range includeAttribs {
for _, a := range proj.NonKeyAttributes {
if attr == *a {
continue attribs
}
}
proj.NonKeyAttributes = append(proj.NonKeyAttributes, &attr)
}
}
Expand Down

0 comments on commit 8764212

Please sign in to comment.