Skip to content
This repository was archived by the owner on Mar 25, 2021. It is now read-only.

Add quotemark type validation to allow early return (#4310)#4344

Merged
JoshuaKGoldberg merged 5 commits intopalantir:masterfrom
isabelleweber:master
Jun 17, 2019
Merged

Add quotemark type validation to allow early return (#4310)#4344
JoshuaKGoldberg merged 5 commits intopalantir:masterfrom
isabelleweber:master

Conversation

@isabelleweber
Copy link
Copy Markdown
Contributor

@isabelleweber isabelleweber commented Dec 5, 2018

PR checklist

Overview of change:

Add quotemark type validation to allow early return if not one of `, ' or ".

Before:

When linting something like (a')...

SyntaxError: Invalid regular expression: /\\)/: Unmatched ')'

After:

No error

CHANGELOG.md entry:

[bugfix] additional quotemark validation

@palantirtech
Copy link
Copy Markdown
Member

Thanks for your interest in palantir/tslint, @isabelleweber! Before we can accept your pull request, you need to sign our contributor license agreement - just visit https://cla.palantir.com/ and follow the instructions. Once you sign, I'll automatically update this pull request.

Copy link
Copy Markdown
Contributor

@JoshuaKGoldberg JoshuaKGoldberg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Functionality looks great - just a style comment and a test fixup.

Comment thread test/rules/quotemark/double/test.ts.lint Outdated
Comment thread src/rules/quotemarkRule.ts Outdated
@JoshuaKGoldberg
Copy link
Copy Markdown
Contributor

👋 @isabelleweber just a heads up - I merged in master and resolved the test feedback. This'll be available in the next TSLint release!

@JoshuaKGoldberg JoshuaKGoldberg merged commit db04231 into palantir:master Jun 17, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

quotemark: Invalid regular expression: /\\)/: Unmatched ')'

4 participants