Skip to content

Commit

Permalink
fix(spellcheck): fix incorrect parsing of global cspell vscode settings
Browse files Browse the repository at this point in the history
  • Loading branch information
Xunnamius committed Nov 30, 2020
1 parent 52377a8 commit c2789bf
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion spellcheck.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,11 @@ const tryToRead = async (path) => {
const asJson = (str) => {
try {
const json = JSON.parse(str.toString('utf-8'));
return [...(json?.['cSpell.words'] || []), ...(json?.['cSpell.ignoreWords'] || [])];
return [
...(json?.['cSpell.words'] || []),
...(json?.['cSpell.userWords'] || []),
...(json?.['cSpell.ignoreWords'] || [])
];
} catch (ignored) {
return [];
}
Expand Down

0 comments on commit c2789bf

Please sign in to comment.