Skip to content

Commit

Permalink
Remove extra new line in code entities
Browse files Browse the repository at this point in the history
  • Loading branch information
painor committed Feb 19, 2024
1 parent 89a0bf8 commit 38fb5ac
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions gramjs/extensions/html.ts
Original file line number Diff line number Diff line change
Expand Up @@ -207,11 +207,7 @@ export class HTMLParser {
html.push(`<blockquote>${entityText}</blockquote>`);
} else if (entity instanceof Api.MessageEntityPre) {
if (entity.language) {
html.push(`<pre>
<code class="language-${entity.language}">
${entityText}
</code>
</pre>`);
html.push(`<pre><code class="language-${entity.language}">${entityText}</code></pre>`);
} else {
html.push(`<pre>${entityText}</pre>`);
}
Expand Down

0 comments on commit 38fb5ac

Please sign in to comment.