X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=server%2Fcontrollers%2Fclient.ts;h=d42e8396df39be22621d0bbcbb0d540bbc506a9b;hb=709756b8e183f67ef9bf8f7bc149af4736260350;hp=e4d69eae7d3cc70130e8b5959e0abee28615b339;hpb=18c8e945089bff49d2c617c411c8a8f4575989ad;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/controllers/client.ts b/server/controllers/client.ts index e4d69eae7..d42e8396d 100644 --- a/server/controllers/client.ts +++ b/server/controllers/client.ts @@ -8,15 +8,14 @@ import { CONFIG, REMOTE_SCHEME, STATIC_PATHS, - STATIC_MAX_AGE + STATIC_MAX_AGE, + OPENGRAPH_COMMENT } from '../initializers' import { root, readFileBufferPromise } from '../helpers' import { VideoInstance } from '../models' const clientsRouter = express.Router() -// TODO: move to constants -const opengraphComment = '' const distPath = join(root(), 'client', 'dist') const embedPath = join(distPath, 'standalone', 'videos', 'embed.html') const indexPath = join(distPath, 'index.html') @@ -85,7 +84,7 @@ function addOpenGraphTags (htmlStringPage: string, video: VideoInstance) { tagsString += '' }) - return htmlStringPage.replace(opengraphComment, tagsString) + return htmlStringPage.replace(OPENGRAPH_COMMENT, tagsString) } function generateWatchHtmlPage (req: express.Request, res: express.Response, next: express.NextFunction) {