Skip to content

Commit e6be65d

Browse files
committed
DraftCleaner: suppress linter errors
1 parent 25adf3f commit e6be65d

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

DraftCleaner/modules/DraftCleaner.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ export class DraftCleaner {
4444
wikicode = this.removeExtraAFCSubmissionTemplates( wikicode );
4545
wikicode = this.moveAFCSubmissionTemplatesToTop( wikicode );
4646

47+
/* eslint-disable indent */
4748
// all ==sections== should start with a capital letter
4849
// after swap, if citation has no spaces on either side, and is not touching two other citations, add a space on the right
4950
// strip [[File: from infobox's image field
@@ -62,6 +63,7 @@ export class DraftCleaner {
6263
// delete ©®™
6364
// convert all <references /> to {{Reflist}}. <references /> doesn't use two column format and looks weird with a large # of references
6465
// remove px from images, should use default
66+
/* eslint-enable indent */
6567

6668
// convert refs toward the end. we want deleteSomeHTMLTags() to run first, to get rid of <nowiki> tags around URLs
6769
wikicode = this.bareURLToRef( wikicode );
@@ -545,11 +547,13 @@ export class DraftCleaner {
545547
const matches = wikicode.match( /==\s*References\s*==/gi );
546548
if ( matches !== null && matches.length > 1 ) {
547549
// run regexes that are likely to delete the extra section
550+
/* eslint-disable indent */
548551
const attempt = wikicode.replace(
549552
`== References ==
550553
<!-- Inline citations added to your article will automatically display here. See en.wikipedia.org/wiki/WP:REFB for instructions on how to add citations. -->
551554
{{reflist}}`
552555
, '' );
556+
/* eslint-enable indent */
553557
const matches2 = attempt.match( /==\s*References\s*==/gi );
554558
if ( matches2.length === 1 ) {
555559
wikicode = attempt.trim();

0 commit comments

Comments
 (0)