Skip to content

Commit

Permalink
chore: use ! instead
Browse files Browse the repository at this point in the history
  • Loading branch information
mmkal committed Apr 6, 2020
1 parent 7aa5855 commit 9e29c64
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/typegen/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ const groupBy = <T>(list: T[], getKey: (value: T) => string | number) => {
const record: Record<string, T[] | undefined> = {}
list.forEach(value => {
const key = getKey(value)
const group = (record[key] = record[key] || [])
group.push(value)
record[key] = record[key] || []
record[key]!.push(value)
})
return record
}
Expand Down

0 comments on commit 9e29c64

Please sign in to comment.