Skip to content

Commit

Permalink
🚨 fix lint
Browse files Browse the repository at this point in the history
  • Loading branch information
nlepage committed Nov 28, 2017
1 parent 22d17d0 commit 4293b87
Showing 1 changed file with 0 additions and 20 deletions.
20 changes: 0 additions & 20 deletions packages/immutadot/src/core/toPath.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,26 +26,6 @@ const toKey = arg => {

const quotes = ['"', '\'']

/**
* Tests whether <code>index</code>th char of <code>str</code> is a quote.<br />
* Quotes are <code>"</code> and <code>'</code>.
* @function
* @param {string} str The string
* @param {number} index Index of the char to test
* @return {{ quoted: boolean, quote: string }} A boolean <code>quoted</code>, true if <code>str.charAt(index)</code> is a quote and the <code>quote</code>.
* @memberof core
* @private
* @since 1.0.0
*/
const isQuoteChar = (str, index) => {
const char = str.charAt(index)
const quote = quotes.find(c => c === char)
return {
quoted: Boolean(quote),
quote,
}
}

const escapedQuotesRegexps = {}
for (const quote of quotes)
escapedQuotesRegexps[quote] = new RegExp(`\\\\${quote}`, 'g')
Expand Down

0 comments on commit 4293b87

Please sign in to comment.