Skip to content

Commit

Permalink
Fix page count incorrect calculation on reupload PDF
Browse files Browse the repository at this point in the history
  • Loading branch information
acestronautical committed Jan 29, 2024
1 parent 62980a9 commit 3ec3033
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "bookbinder",
"version": "1.3.1",
"version": "1.3.2",
"description": "An app to rearrange PDF pages for printing for bookbinding",
"type": "module",
"scripts": {
Expand Down
2 changes: 1 addition & 1 deletion src/book.js
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ export class Book {
* Populates [this.orderedpages] (array [0, 1, ... this.page_sheets * # of sheets])
*/
createpagelist() {
this.pagecount = (this.managedDoc == null) ? this.currentdoc.getPageCount() : this.managedDoc.getPageCount();
this.pagecount = this.currentdoc.getPageCount();
this.orderedpages = Array.from({ length: this.pagecount }, (x, i) => i);

if (this.flyleaf) {
Expand Down

0 comments on commit 3ec3033

Please sign in to comment.