diff options
Diffstat (limited to 'server/lib')
-rw-r--r-- | server/lib/client-html.ts | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/server/lib/client-html.ts b/server/lib/client-html.ts index e7e439bfe..74788af52 100644 --- a/server/lib/client-html.ts +++ b/server/lib/client-html.ts | |||
@@ -3,6 +3,7 @@ import { readFile } from 'fs-extra' | |||
3 | import { join } from 'path' | 3 | import { join } from 'path' |
4 | import validator from 'validator' | 4 | import validator from 'validator' |
5 | import { toCompleteUUID } from '@server/helpers/custom-validators/misc' | 5 | import { toCompleteUUID } from '@server/helpers/custom-validators/misc' |
6 | import { root } from '@shared/core-utils' | ||
6 | import { escapeHTML } from '@shared/core-utils/renderer' | 7 | import { escapeHTML } from '@shared/core-utils/renderer' |
7 | import { sha256 } from '@shared/extra-utils' | 8 | import { sha256 } from '@shared/extra-utils' |
8 | import { HTMLServerConfig } from '@shared/models' | 9 | import { HTMLServerConfig } from '@shared/models' |
@@ -344,11 +345,11 @@ class ClientHtml { | |||
344 | { cookie: req.cookies?.clientLanguage, paramLang, acceptLanguage: req.headers['accept-language'] } | 345 | { cookie: req.cookies?.clientLanguage, paramLang, acceptLanguage: req.headers['accept-language'] } |
345 | ) | 346 | ) |
346 | 347 | ||
347 | return join(__dirname, '../../../client/dist/' + buildFileLocale(lang) + '/index.html') | 348 | return join(root(), 'client', 'dist', buildFileLocale(lang), 'index.html') |
348 | } | 349 | } |
349 | 350 | ||
350 | private static getEmbedPath () { | 351 | private static getEmbedPath () { |
351 | return join(__dirname, '../../../client/dist/standalone/videos/embed.html') | 352 | return join(root(), 'client', 'dist', 'standalone', 'videos', 'embed.html') |
352 | } | 353 | } |
353 | 354 | ||
354 | private static addManifestContentHash (htmlStringPage: string) { | 355 | private static addManifestContentHash (htmlStringPage: string) { |