Utente:Daimona Eaytoy/Massblock.js: differenze tra le versioni
Contenuto cancellato Contenuto aggiunto
Inizio nuova versione |
m min |
||
Riga 44:
reason: wpMassBlockReasons === "other" ? wpMassBlockReason : wpMassBlockReasons + (wpMassBlockReason ? ": " + wpMassBlockReason : ""),
user: user
}
.then(
function(data) {
Riga 75:
function doEditUserPage() {
new mw.Api().postWithEditToken(
action: 'edit',
title: 'User:' + user,
Riga 81:
summary: wpMassBlockSummaryUser,
watchlist: 'nochange'
}
userpageedited++;
}
//If not edited, add the title to the "failed" array and a description of the error to the "error" array.
failed.push("User talk:" + user);
error.push(
}
}
function doEditTalk() {
new mw.Api().postWithEditToken(
action: 'edit',
title: 'User talk:' + user,
Riga 97:
summary: wpMassBlockSummaryTalk,
watchlist: 'nochange'
}
talkpageedited++;
}
//If not edited, add the title to the "failed" array and a description of the error to the "error" array.
failed.push("User talk:" + user);
error.push(
}
}
Riga 158:
document.getElementById("wpMassBlockReasons").onchange = function() {
var maxlength = (document.getElementById("wpMassBlockReasons").value === "other" ? 255 :
document.getElementById("wpMassBlockReason").setAttribute("maxlength", maxlength);
};
}
if (mw.config.get("wgNamespaceNumber") === -1 &&
(mw.config.get("wgTitle") == "Massblock" || mw.config.get("wgTitle") === "MassBlock") && /sysop/.test(mw.config.get("wgUserGroups")) ) { $(massblockform);
}
|