Skip to content

Commit

Permalink
chore: lint
Browse files Browse the repository at this point in the history
  • Loading branch information
imjohnbo committed Apr 21, 2022
1 parent fc3e6cc commit d3ec435
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/paste-markdown-html.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,7 @@ function convertToMarkdown(plaintext: string, walker: TreeWalker): string {
// Walk through the DOM tree
while (currentNode && index < NODE_LIMIT) {
index++
const text = isLink(currentNode)
? currentNode.textContent || ''
: (currentNode.firstChild as Text)?.wholeText || ''
const text = isLink(currentNode) ? currentNode.textContent || '' : (currentNode.firstChild as Text)?.wholeText || ''

// No need to transform whitespace
if (isEmptyString(text)) {
Expand Down

0 comments on commit d3ec435

Please sign in to comment.