Open
Description
Community Note
- Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
- Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request
- If you are interested in working on this issue or have submitted a pull request, please leave a comment
Affected Resource(s)
On line 135 in cdktf/lib/private/tokens/encoding.ts
:
if (startMatch && endMatch) {
if (startMatch.index > startIndex && startMatch.index > startIndex) { // this conditional is repeated?
const lede = this.str.substring(
startIndex,
Math.min(startMatch.index, endMatch.index)
);
fragments.addLiteral(lede);
}
In the second line, the if
statement has the same conditional repeated. Is this intentional-- am I missing some crucial TS knowledge?
If I had to guess what the second conditional would be, then I would guess endMatch.index > startIndex
. But I'm not so confident in the logic here to definitively open that PR.