File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -37,7 +37,7 @@ export async function buildSearchIndex() {
3737 } )
3838 const dom = new JSDOM . JSDOM ( data )
3939 const title =
40- dom . window . document . querySelector ( "title" ) ?. innerHTML ||
40+ dom . window . document . querySelector ( "title" ) ?. textContent ||
4141 "Page " + webPath
4242 const description =
4343 dom . window . document
Original file line number Diff line number Diff line change @@ -17,9 +17,9 @@ export function GET({ url }) {
1717
1818 let body = `<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
1919 <channel>
20- <title>${ blogInfo . name } </title>
20+ <title>${ encodeXML ( blogInfo . name ) } </title>
2121 <link>${ url . origin } /blog</link>
22- <description>${ blogInfo . description } </description>
22+ <description>${ encodeXML ( blogInfo . description ) } </description>
2323 <atom:link href="${ url . origin } /blog/rss.xml" rel="self" type="application/rss+xml" />`
2424 for ( const post of sortedBlogPosts ) {
2525 body += `
You can’t perform that action at this time.
0 commit comments