Adds mystery description fallback
If a message had no obvious text because it didn't have a content type of post, use the mystery description as to not break the `postSnippet()` function and give a valid snippet in the title.
This commit is contained in:
parent
8ce7d73edd
commit
b4f0509e21
|
@ -711,7 +711,7 @@ exports.threadView = ({ messages }) => {
|
|||
const rootMessage = messages[0];
|
||||
const rootAuthorName = rootMessage.value.meta.author.name;
|
||||
const rootSnippet = postSnippet(
|
||||
lodash.get(rootMessage, "value.content.text")
|
||||
lodash.get(rootMessage, "value.content.text", i18n.mysteryDescription)
|
||||
);
|
||||
return template([`@${rootAuthorName}: `, rootSnippet], thread(messages));
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue