refactoring

This commit is contained in:
Philipp Kühn
2021-01-28 09:57:20 +01:00
parent 4407d9a3d1
commit 6a5dde0101
5 changed files with 28 additions and 30 deletions

View File

@@ -24,7 +24,7 @@ export default function (regexp: RegExp, markType: MarkType, getAttributes?: Fun
const { excluded } = item.mark.type
return excluded.find((type: MarkType) => type.name === markType.name)
})
.filter(item => item.end > textStart)
.filter(item => item.to > textStart)
if (excludedMarks.length) {
return null