diff --git a/packages/astro/src/runtime/server/escape.ts b/packages/astro/src/runtime/server/escape.ts index 7610a3dee..0212d803d 100644 --- a/packages/astro/src/runtime/server/escape.ts +++ b/packages/astro/src/runtime/server/escape.ts @@ -32,8 +32,8 @@ export const markHTMLString = (value: any) => { export function unescapeHTML(str: any) { // If a promise, await the result and mark that. - if(!!str && typeof str === 'object' && typeof str.then === 'function') { - return Promise.resolve(str).then(value => { + if (!!str && typeof str === 'object' && typeof str.then === 'function') { + return Promise.resolve(str).then((value) => { return markHTMLString(value); }); } diff --git a/packages/astro/src/runtime/server/index.ts b/packages/astro/src/runtime/server/index.ts index cd02deaa9..c6d7c9e53 100644 --- a/packages/astro/src/runtime/server/index.ts +++ b/packages/astro/src/runtime/server/index.ts @@ -1,11 +1,6 @@ export { createAstro } from './astro-global.js'; export { renderEndpoint } from './endpoint.js'; -export { - escapeHTML, - HTMLString, - markHTMLString, - unescapeHTML, -} from './escape.js'; +export { escapeHTML, HTMLString, markHTMLString, unescapeHTML } from './escape.js'; export type { Metadata } from './metadata'; export { createMetadata } from './metadata.js'; export {