Add default text if the post.content variable is empty
This commit is contained in:
@@ -89,6 +89,7 @@ exports.sendPost = (post, source, channel, callback) => {
|
||||
else if (postText.length === 0) postText = `*This post has no content* [Direct Link](${post.link})`;
|
||||
postContent = postText;
|
||||
}
|
||||
else postText = `*This post has no content* [Direct Link](${post.link})`;
|
||||
|
||||
// Check for embedded youtube videos and add the first four as links
|
||||
const ytVideos = String(post.content).match(youtubeVideoRegex);
|
||||
|
||||
Reference in New Issue
Block a user