File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed
Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -25,11 +25,11 @@ export async function showLintConfig() {
2525 return ;
2626 }
2727 await import ( '@/cm/jsonlint-bundle' ) ;
28+ isStylelint = linter === 'stylelint' ;
2829 const config = await getLZValue ( LZ_KEY [ linter ] ) ;
2930 const defaults = DEFAULTS [ linter ] ;
3031 const title = t ( 'linterConfigPopupTitle' , isStylelint ? 'Stylelint' : 'CSSLint' ) ;
3132 const activeRules = new Set ( getActiveRules ( ) ) ;
32- isStylelint = linter === 'stylelint' ;
3333 knownRules = KNOWN_RULES [ linter ] || (
3434 KNOWN_RULES [ linter ] = new Set ( (
3535 isStylelint
@@ -49,9 +49,10 @@ export async function showLintConfig() {
4949 delete cfg [ id ] ;
5050 }
5151 }
52- for ( const id of missingRules ) {
53- cfg [ id ] = isStylelint ? false : 0 ;
54- }
52+ // Not adding for stylelint because some rules expect a string value
53+ if ( ! isStylelint )
54+ for ( const id of missingRules )
55+ cfg [ id ] = 0 ;
5556 }
5657 defaultConfig [ linter ] = stringifyConfig ( defaults ) ;
5758 popup = showCodeMirrorPopup ( title , null , {
You can’t perform that action at this time.
0 commit comments