There was an error while loading. Please reload this page.
1 parent bdd3ce2 commit 200eee2Copy full SHA for 200eee2
lib/templates/imageFunction.js
@@ -7,7 +7,7 @@ exports.handler = async (event) => {
7
const quality = parseInt(q);
8
9
const imageUrl = url.startsWith("/")
10
- ? `${process.env.URL || "http://localhost:8888"}${url}`
+ ? `${process.env.DEPLOY_URL || `http://${event.headers.host}`}${url}`
11
: url;
12
const image = await jimp.read(imageUrl);
13
0 commit comments