Skip to content
Snippets Groups Projects
Commit 64b3254d authored by Zdravko Iliev's avatar Zdravko Iliev
Browse files

fix typo

parent dc102bbd
Branches
No related tags found
1 merge request!1Draft: Resolve "[Document Sealing] Implement PDF parser"
Pipeline #50153 failed
......@@ -50,18 +50,14 @@ class PDFparser {
const img = yield pdfDoc.embedPng(imgBytes);
const scaled = img.scale(scaleFactor);
const pages = pdfDoc.getPages();
console.log(coords);
for (let index = 0; index < pages.length; index++) {
const page = pages[index];
console.log(coords[index + 1]);
console.log(typeof coords[index + 1] !== "undefined");
const x = typeof coords[index + 1] !== "undefined"
? parseFloat(coords[index + 1].x)
: null;
const y = typeof coords[index + 1] !== "undefined"
? parseFloat(coords[index + 1].y)
: null;
console.log(x, y);
if (x && y) {
page.drawImage(img, {
x,
......
......@@ -65,14 +65,9 @@ class PDFparser {
const pages = pdfDoc.getPages();
console.log(coords);
for (let index = 0; index < pages.length; index++) {
const page = pages[index];
console.log(coords[index + 1]);
console.log(typeof coords[index + 1] !== "undefined");
const x =
typeof coords[index + 1] !== "undefined"
? parseFloat(coords[index + 1].x)
......@@ -83,7 +78,6 @@ class PDFparser {
? parseFloat(coords[index + 1].y)
: null;
console.log(x, y);
if (x && y) {
page.drawImage(img, {
x,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment