aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--server/lib/client-html.ts2
-rw-r--r--server/tests/client.ts8
2 files changed, 5 insertions, 5 deletions
diff --git a/server/lib/client-html.ts b/server/lib/client-html.ts
index ae335240e..a557c090f 100644
--- a/server/lib/client-html.ts
+++ b/server/lib/client-html.ts
@@ -162,7 +162,7 @@ class ClientHtml {
162 let customHtml = ClientHtml.addTitleTag(html, escapeHTML(videoPlaylist.name)) 162 let customHtml = ClientHtml.addTitleTag(html, escapeHTML(videoPlaylist.name))
163 customHtml = ClientHtml.addDescriptionTag(customHtml, mdToPlainText(videoPlaylist.description)) 163 customHtml = ClientHtml.addDescriptionTag(customHtml, mdToPlainText(videoPlaylist.description))
164 164
165 const url = videoPlaylist.getWatchStaticPath() 165 const url = WEBSERVER.URL + videoPlaylist.getWatchStaticPath()
166 const originUrl = videoPlaylist.url 166 const originUrl = videoPlaylist.url
167 const title = escapeHTML(videoPlaylist.name) 167 const title = escapeHTML(videoPlaylist.name)
168 const siteName = escapeHTML(CONFIG.INSTANCE.NAME) 168 const siteName = escapeHTML(CONFIG.INSTANCE.NAME)
diff --git a/server/tests/client.ts b/server/tests/client.ts
index 9c27a7aae..4cbdb2cb3 100644
--- a/server/tests/client.ts
+++ b/server/tests/client.ts
@@ -119,7 +119,7 @@ describe('Test a client controllers', function () {
119 const port = servers[0].port 119 const port = servers[0].port
120 120
121 const expectedLink = '<link rel="alternate" type="application/json+oembed" href="http://localhost:' + port + '/services/oembed?' + 121 const expectedLink = '<link rel="alternate" type="application/json+oembed" href="http://localhost:' + port + '/services/oembed?' +
122 `url=http%3A%2F%2Flocalhost%3A${port}%2Fw%2F${servers[0].store.video.uuid}" ` + 122 `url=http%3A%2F%2Flocalhost%3A${port}%2Fw%2F${servers[0].store.video.shortUUID}" ` +
123 `title="${servers[0].store.video.name}" />` 123 `title="${servers[0].store.video.name}" />`
124 124
125 expect(res.text).to.contain(expectedLink) 125 expect(res.text).to.contain(expectedLink)
@@ -140,7 +140,7 @@ describe('Test a client controllers', function () {
140 const port = servers[0].port 140 const port = servers[0].port
141 141
142 const expectedLink = '<link rel="alternate" type="application/json+oembed" href="http://localhost:' + port + '/services/oembed?' + 142 const expectedLink = '<link rel="alternate" type="application/json+oembed" href="http://localhost:' + port + '/services/oembed?' +
143 `url=http%3A%2F%2Flocalhost%3A${port}%2Fw%2Fp%2F${playlist.uuid}" ` + 143 `url=http%3A%2F%2Flocalhost%3A${port}%2Fw%2Fp%2F${playlist.shortUUID}" ` +
144 `title="${playlistName}" />` 144 `title="${playlistName}" />`
145 145
146 expect(res.text).to.contain(expectedLink) 146 expect(res.text).to.contain(expectedLink)
@@ -178,7 +178,7 @@ describe('Test a client controllers', function () {
178 expect(text).to.contain(`<meta property="og:title" content="${videoName}" />`) 178 expect(text).to.contain(`<meta property="og:title" content="${videoName}" />`)
179 expect(text).to.contain(`<meta property="og:description" content="${videoDescriptionPlainText}" />`) 179 expect(text).to.contain(`<meta property="og:description" content="${videoDescriptionPlainText}" />`)
180 expect(text).to.contain('<meta property="og:type" content="video" />') 180 expect(text).to.contain('<meta property="og:type" content="video" />')
181 expect(text).to.contain(`<meta property="og:url" content="${servers[0].url}/w/${servers[0].store.video.uuid}" />`) 181 expect(text).to.contain(`<meta property="og:url" content="${servers[0].url}/w/${servers[0].store.video.shortUUID}" />`)
182 } 182 }
183 183
184 async function watchPlaylistPageTest (path: string) { 184 async function watchPlaylistPageTest (path: string) {
@@ -188,7 +188,7 @@ describe('Test a client controllers', function () {
188 expect(text).to.contain(`<meta property="og:title" content="${playlistName}" />`) 188 expect(text).to.contain(`<meta property="og:title" content="${playlistName}" />`)
189 expect(text).to.contain(`<meta property="og:description" content="${playlistDescription}" />`) 189 expect(text).to.contain(`<meta property="og:description" content="${playlistDescription}" />`)
190 expect(text).to.contain('<meta property="og:type" content="video" />') 190 expect(text).to.contain('<meta property="og:type" content="video" />')
191 expect(text).to.contain(`<meta property="og:url" content="${servers[0].url}/w/p/${playlist.uuid}" />`) 191 expect(text).to.contain(`<meta property="og:url" content="${servers[0].url}/w/p/${playlist.shortUUID}" />`)
192 } 192 }
193 193
194 it('Should have valid Open Graph tags on the account page', async function () { 194 it('Should have valid Open Graph tags on the account page', async function () {