Skip to content

Commit

Permalink
download page fix with no description
Browse files Browse the repository at this point in the history
  • Loading branch information
Xinecraft committed Jan 11, 2024
1 parent 45883af commit 07af6f4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/Models/Download.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,10 @@ public function getFileAttribute()
return $file;
}

public function getDescriptionHtmlAttribute(): string
public function getDescriptionHtmlAttribute(): ?string
{
$converter = new GithubFlavoredMarkdownConverter();

return $converter->convertToHtml($this->description);
return $this->description ? $converter->convertToHtml($this->description) : null;
}
}

0 comments on commit 07af6f4

Please sign in to comment.