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

Implemented fix for quotemark rule #1790

Merged
merged 1 commit into from
Nov 27, 2016
Merged

Conversation

devoto13
Copy link
Contributor

PR checklist

  • Addresses an existing issue: #0000
  • New feature, bugfix, or enhancement
    • Includes tests
  • Documentation update

What changes did you make?

Added fix for the quotemark rule.

Is there anything you'd like reviewers to focus on?

(optional)

@palantirtech
Copy link
Member

Thanks for your interest in palantir/tslint, @devoto13! 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.

@@ -116,7 +116,13 @@ class QuotemarkWalker extends Lint.RuleWalker {
? Rule.SINGLE_QUOTE_FAILURE
: Rule.DOUBLE_QUOTE_FAILURE;

this.addFailure(this.createFailure(position, width, failureMessage));
const quotemarkToEscape = this.quoteMark === QuoteMark.SINGLE_QUOTES ? "'" : "\"";
Copy link
Contributor

Choose a reason for hiding this comment

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

isn't this the same as expectedQuoteMark?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

You're right! Fixed.

@nchen63 nchen63 merged commit d46f74f into palantir:master Nov 27, 2016
@nchen63
Copy link
Contributor

nchen63 commented Nov 27, 2016

@devoto13 thanks!

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.

3 participants