fix: no group for the description if it's missing

Signed-off-by: Akos Kitta <a.kitta@arduino.cc>
This commit is contained in:
Akos Kitta 2023-03-16 10:12:02 +01:00
parent fa4626bf14
commit 03355903b9

View File

@ -213,7 +213,7 @@ export class ListItemRenderer<T extends ArduinoComponent> {
let content = `\n\n${summary}`;
// do not repeat the same info if paragraph and sentence are the same
// example: https://github.com/arduino-libraries/ArduinoCloudThing/blob/8cbcee804e99fed614366c1b87143b1f1634c45f/library.properties#L5-L6
if (description !== summary) {
if (description && description !== summary) {
content += `\n_____\n\n${description}`;
}
return `${title}\n\n____${content}\n\n____\n${TopicLabel}: \`${item.category}\``;