מדיה ויקי:Gadget-HotCat.js: הבדלים בין גרסאות בדף

מ Fix typo in comment :-)
Do nothing for non-logged-in users
שורה 29: שורה 29:


function hotcat_check_upload () {
function hotcat_check_upload () {
   if ( wgNamespaceNumber != -1 || wgTitle != "Upload" ) return ; // Not "Special:Upload"
  // Don't do anything if not "Special:Upload", or user not logged in.
   if ( wgNamespaceNumber != -1 || wgTitle != "Upload" || wgUser == null) return ;
   hotcat_upload = 1 ;
   hotcat_upload = 1 ;
   var ip = document.getElementById ( "wpWatchthis" ) ;
   var ip = document.getElementById ( "wpWatchthis" ) ;