mirror of
https://github.com/Brandon-Rozek/website.git
synced 2025-10-08 22:21:12 +00:00
Allow text/html cache display on offline page
This commit is contained in:
parent
5f0441e629
commit
05e5786a80
2 changed files with 2 additions and 2 deletions
|
@ -46,7 +46,7 @@ async function listPages() {
|
|||
if (url.includes('/blog')) {
|
||||
console.log(url)
|
||||
const post = await cache.match(request);
|
||||
if (post.headers.get('content-type') === 'text/html') {
|
||||
if (post.headers.get('content-type').includes('text/html')) {
|
||||
const body = await post.text();
|
||||
console.log(body)
|
||||
const title = body.match(/<title>(.*)<\/title>/)[1];
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue