Skip to content

Commit

Permalink
line break, rename variable, small changes
Browse files Browse the repository at this point in the history
  • Loading branch information
NovemLinguae committed Nov 27, 2024
1 parent 9aa7ae4 commit a72ccc6
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions src/modules/submissions.js
Original file line number Diff line number Diff line change
Expand Up @@ -2615,6 +2615,7 @@
const welcomeDraftCategories = [
'Category:Wikipedians who have received an AfC welcome message'
];

$.each( categories, ( _, cat ) => {
if ( welcomeDraftCategories.indexOf( cat ) !== -1 ) {
hasWelcomeDraftCat = true;
Expand All @@ -2626,11 +2627,11 @@
} );
}

$.when( shouldTeahouse, shouldWelcomeUser ).then( ( teahouse, welcomeDraft ) => {
let message;
$.when( shouldTeahouse, shouldWelcomeUser ).then( ( teahouse, welcome ) => {
let message = '';

if ( welcomeDraft ) {
message = AFCH.msg.get( 'welcomedraft-user' ) + '\n\n';
if ( welcome ) {
message += AFCH.msg.get( 'welcomedraft-user' ) + '\n\n';
}
if ( isDecline ) {
message += AFCH.msg.get( 'declined-submission', {
Expand Down

0 comments on commit a72ccc6

Please sign in to comment.