Skip to content

Commit 0754489

Browse files
authored
Merge pull request #483 from zeotuan/master
Fix /api/countries/[country]/og Does not work when window 64 bit install Chrome 64 bit
2 parents 04f89e9 + ba1cf54 commit 0754489

2 files changed

Lines changed: 5 additions & 3 deletions

File tree

util/options.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,9 @@
11
import chrome from "chrome-aws-lambda";
22
const exePath =
33
process.platform === "win32"
4-
? "C:\\Program Files (x86)\\Google\\Chrome\\Application\\chrome.exe"
4+
? process.arch === "x64" // add additional check to see if win is 64 or 32 bit
5+
? "C:\\Program Files\\Google\\Chrome\\Application\\chrome.exe"
6+
: "C:\\Program Files (x86)\\Google\\Chrome\\Application\\chrome.exe"
57
: process.platform === "linux"
68
? "/usr/bin/chromium-browser"
79
: "/Applications/Google Chrome.app/Contents/MacOS/Google Chrome";

util/template.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
import { readFileSync } from "fs";
22

33
const regularInter = readFileSync(
4-
`${__dirname}/../../../fonts/Inter-Regular.woff2`
4+
`${__dirname}/../fonts/Inter-Regular.woff2`
55
).toString("base64");
66
const boldInter = readFileSync(
7-
`${__dirname}/../../../fonts/Inter-Bold.woff2`
7+
`${__dirname}/../fonts/Inter-Bold.woff2`
88
).toString("base64");
99

1010
function formatNumber(num: number): string {

0 commit comments

Comments
 (0)