_ _    _ _____  ___   __                       
 __      _(_) | _(_)___ / ( _ ) / /_   ___ ___  _ __ ___  
 \ \ /\ / / | |/ / | |_ \ / _ \| '_ \ / __/ _ \| '_ ` _ \ 
  \ V  V /| |   <| |___) | (_) | (_) | (_| (_) | | | | | |
   \_/\_/ |_|_|\_\_|____/ \___/ \___(_)___\___/|_| |_| |_|

User:Danski454/ReviewWarn.js

This article will address User:Danski454/ReviewWarn.js, a topic of great relevance today that has generated extensive debate and questions in different areas. In order to provide a broad and enriching vision of this topic, various aspects will be analyzed that will allow us to understand its importance and impact on society. Through the information presented, it is intended to generate a critical and reflective analysis that contributes to the enrichment of knowledge about User:Danski454/ReviewWarn.js and encourages reflection on its impact on current reality.
var reverteduser = null;
$(document).ready(function(){
	if(mw.config.get( 'wgPageName' ) === 'Special:RevisionReview' && mw.config.get( 'wgUserGroups' ) !== null &&
	( mw.config.get( 'wgUserGroups' ).indexOf('sysop') !== -1 || mw.config.get( 'wgUserGroups' ).indexOf('reviewer') !== -1 )){ //only run if user can review and is on Special:RevisionReview
		$('#mw-content-text bdi').each(function( index ) { // check if all revisions were madeby the same user, if so, reverteduser holds their UN oterwise it is null
			if (index === 0){
				reverteduser = $(this).text();
			} else{
				if (reverteduser !== $(this).text()){
					reverteduser = null;
				}
			}
		});
		if (reverteduser !== null){
			$('form').attr('onsubmit', 'return ReviewWarnLoadUserTalk()');
			console.log('ReviewWarn:: linked reject button to User talk:' + reverteduser);
		}
	}
});

function ReviewWarnLoadUserTalk(){
	var revertedpage = $('#mw-content-text .plainlinks a').first().text();
	window.open('https://en.wikipedia.org/w/index.php?title=User_talk:' + encodeURIComponent(reverteduser.replace(' ', '_')) + '&action=edit&preview=yes&vanarticle=' + encodeURIComponent(revertedpage));
	return true; //submit the form
}