From 0b41a4e56f8a1741118ed798f4f1ba04e1ec7df5 Mon Sep 17 00:00:00 2001 From: Nick Playfair <842413+nplayfair@users.noreply.github.com> Date: Fri, 13 Jun 2025 19:37:22 +0100 Subject: [PATCH] Fix formatting and add a few comments --- index.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/index.js b/index.js index 2c75f00..aa0aa0e 100644 --- a/index.js +++ b/index.js @@ -1,10 +1,13 @@ +//Modules const AdmZip = require('adm-zip'); const fs = require('fs-extra'); const path = require('path'); const pcbStackup = require('pcb-stackup'); const sharp = require('sharp'); const { Readable } = require('stream'); +const { Buffer } = require('node:buffer'); +//Class definition class ImageGenerator { constructor(folderConfig, imgConfig, layerNames) { this.tmpDir = folderConfig.tmpDir; @@ -121,7 +124,7 @@ class ImageGenerator { ImageGenerator.extractArchive(gerber, this.tmpDir); ImageGenerator.getLayers( path.join(this.tmpDir, 'archive'), - this.layerNames + this.layerNames, ) .then(pcbStackup) .then((stackup) => { @@ -169,7 +172,7 @@ class ImageGenerator { ImageGenerator.extractArchive(gerber, this.tmpDir); ImageGenerator.getLayers( path.join(this.tmpDir, 'archive'), - this.layerNames + this.layerNames, ) .then(pcbStackup) .then((stackup) => {