Skip to content

Commit

Permalink
Merge pull request #396 from DasSkelett/fix/modpack-og-null-description
Browse files Browse the repository at this point in the history
  • Loading branch information
DasSkelett authored Oct 7, 2021
2 parents 247f180 + 0e8a0f6 commit 70b1583
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions KerbalStuff/common.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ def allow_iframe_attr(tagname: str, attrib: str, val: str) -> bool:
filters=[bleach.linkifier.LinkifyFilter])


def first_paragraphs(text: str) -> str:
return '\n\n'.join(PARAGRAPH_PATTERN.split(text)[0:3])
def first_paragraphs(text: Optional[str]) -> str:
return '\n\n'.join(PARAGRAPH_PATTERN.split(text)[0:3]) if text else ''


def many_paragraphs(text: str) -> bool:
Expand Down

0 comments on commit 70b1583

Please sign in to comment.