#112 Improve og:image base URL function

This commit is contained in:
Alan Grainger
2025-07-21 12:25:21 +02:00
parent d9bd631d16
commit 96fbbb5714
4 changed files with 11 additions and 4 deletions
+1 -1
View File
@@ -91,7 +91,7 @@ class Render {
// publicBaseUrl is used for the og:image, which requires a fully qualified URL.
// You can specify this in your config.json file, or send it dynamically as a `host` header
const publicBaseUrl = getConfigOption('ipp.publicBaseUrl', null) || res.req.headers.publicBaseUrl || ''
const publicBaseUrl = process.env.PUBLIC_BASE_URL || res.req.headers.publicBaseUrl || (res.req.protocol + '://' + res.req.headers.host)
for (const asset of share.assets) {
let video, downloadUrl