diff --git a/lib/routes/chub/characters.ts b/lib/routes/chub/characters.ts
index 0ed1d8a44..ae237a85f 100644
--- a/lib/routes/chub/characters.ts
+++ b/lib/routes/chub/characters.ts
@@ -1,7 +1,16 @@
+import MarkdownIt from 'markdown-it';
+
import type { Route } from '@/types';
import ofetch from '@/utils/ofetch';
import { parseDate } from '@/utils/parse-date';
+const md = MarkdownIt({
+ breaks: true,
+ html: true,
+ linkify: true,
+ typographer: true,
+});
+
export const route: Route = {
path: '/characters',
categories: ['new-media'],
@@ -14,6 +23,10 @@ export const route: Route = {
},
};
+function convertUndefinedToString(value: any): string {
+ return value === undefined ? '' : value.toString();
+}
+
async function handler() {
const hostURL = 'https://www.chub.ai/characters';
const apiURL = 'https://api.chub.ai/search';
@@ -52,13 +65,13 @@ async function handler() {
link: hostURL,
item: nodes.map((item) => ({
title: item.name,
- description: `${item.tagline}
${item.description}`,
+ description: `