Skip to content

Commit

Permalink
refactor: remove comments
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelTaylor3D committed Sep 27, 2023
1 parent 3b1beb4 commit a2c9616
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/components/blocks/Pagination.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,10 +70,9 @@ const PagesContainer = styled(ControlsContainer)`

const Pagination = withTheme(
({ pages, current, showLast = false, callback }) => {
// No need to increment currentPageNumber by 1 here
const currentPageNumber = current;
const numberOfPages = pages && pages !== 0 ? pages : 1;
const changeCurrentPageTo = value => callback(value); // Remove the - 1 here
const changeCurrentPageTo = value => callback(value);
const backButtonIsDisabled = currentPageNumber === 1;
const nextButtonIsDisabled = currentPageNumber === numberOfPages;

Expand Down

0 comments on commit a2c9616

Please sign in to comment.