Skip to content

Commit 3b8b460

Browse files
authored
Merge pull request #33 from TheGoop/api
hot fix for post preview
2 parents 083f39f + 87077aa commit 3b8b460

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

apis/backendApi/postAPI.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ def get_post_preview(db, body):
5757
returnPost['flair'] = post.flair
5858
words = post.message.split(' ')
5959
if len(words) > 100:
60+
words = words[:100]
6061
words.append("...")
6162
returnPost['content'] = " ".join(words)
6263
returnPayload.append(returnPost)

0 commit comments

Comments
 (0)