Skip to content

Commit

Permalink
isAllRowsSelected can only be true if there are rows. (#1504)
Browse files Browse the repository at this point in the history
  • Loading branch information
Codar97 authored and tannerlinsley committed Sep 9, 2019
1 parent f829cd0 commit aea76fa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/plugin-hooks/useRowSelect.js
Expand Up @@ -38,7 +38,7 @@ function useMain(instance) {
[]
)

const isAllRowsSelected = rowPaths.length === selectedRows.length
const isAllRowsSelected = rowPaths.length > 0 && rowPaths.length === selectedRows.length

const toggleRowSelectedAll = set => {
setState(old => {
Expand Down

0 comments on commit aea76fa

Please sign in to comment.