Skip to content

Commit

Permalink
fix(ResourceTable): Change property used to determine total item coun…
Browse files Browse the repository at this point in the history
…t from 'total' to 'count'
  • Loading branch information
wms committed Sep 19, 2017
1 parent bb42f26 commit 944f19d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/components/ResourceTable.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ describe('default behaviour', () => {
const result = {
embedded: jest.fn((name: string) => widgets),
properties: {
total: widgets.length
count: widgets.length
}
}

Expand Down
2 changes: 1 addition & 1 deletion src/components/ResourceTable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ export class ResourceTable extends React.Component<Props, State> {
return link.fetch(params)
.then((result: Resource) => {
this.setState({
total: result.properties.total,
total: result.properties.count,
rows: result.embedded(embedded || rel) as Resource[]
})
})
Expand Down

0 comments on commit 944f19d

Please sign in to comment.