40,275
edits
m (no need for that space) |
m (some debugging) |
||
const pid = Object.keys(resp.query.pages)[0]
const new_files = []
if (!resp.query.pages[pid].linkshere) { console.warn('no files link to '+ page_name); return; }
const pages = resp.query.pages[pid].linkshere.map(function(page) { return page.title.split(':')[1] })
for (var i in pages) {
}
// don't change the page if there's nothing to change
if (new_files.length == 0) { console.warn('no new files link to '+ page_name); return; }
console.log('these files link to', page_name, new_files);
// TODO: make into a dropdown notice thing?
if (edit.value.includes('</gallery>')) {
// add the lines to the end of the current gallery
|