fix: some style

This commit is contained in:
Kilu 2024-06-28 19:31:16 +08:00
parent 6cb81d7b7c
commit 37864a07ce

View File

@ -92,8 +92,10 @@ const createServer = async (req) => {
let title = 'AppFlowy';
const url = 'https://appflowy.io';
let image = logo;
try {
// Inject meta data into the HTML to support SEO and social sharing
if (metaData) {
if (metaData && metaData.view) {
title = `${metaData.view.name} | AppFlowy`;
try {
@ -105,6 +107,9 @@ const createServer = async (req) => {
// Do nothing
}
}
} catch (error) {
logger.error(`Error injecting meta data: ${error}`);
}
$('title').text(title);
setOrUpdateMetaTag($, 'meta[name="description"]', 'name', description);