Skip to content

Commit

Permalink
linebreak-style: remove useless variable
Browse files Browse the repository at this point in the history
  • Loading branch information
wooorm committed Jun 4, 2018
1 parent 2b9706a commit 22f7092
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions packages/remark-lint-linebreak-style/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,6 @@ var location = require('vfile-location')

module.exports = rule('remark-lint:linebreak-style', linebreakStyle)

var sequences = {unix: '\n', windows: '\r\n'}
var escaped = {unix: '\\n', windows: '\\r\\n'}
var types = {true: 'windows', false: 'unix'}

Expand All @@ -69,7 +68,7 @@ function linebreakStyle(tree, file, pref) {
type = types[content.charAt(index - 1) === '\r']

if (pref) {
if (sequences[pref] !== sequences[type]) {
if (pref !== type) {
reason =
'Expected linebreaks to be ' +
pref +
Expand Down

0 comments on commit 22f7092

Please sign in to comment.