Made uploadLinksBox() use quickUserCan() to avoid title blacklist queries
authorAaron Schulz <aschulz@wikimedia.org>
Fri, 11 Sep 2015 00:57:29 +0000 (17:57 -0700)
committerAaron Schulz <aschulz@wikimedia.org>
Fri, 11 Sep 2015 00:57:29 +0000 (17:57 -0700)
Change-Id: I48347acfa70020313d6860d95bc9f286ced9400b

includes/page/ImagePage.php

index 62dd1e3..43b12b2 100644 (file)
@@ -709,7 +709,7 @@ EOT
                $out->addHTML( "<ul>\n" );
 
                # "Upload a new version of this file" link
-               $canUpload = $this->getTitle()->userCan( 'upload', $this->getContext()->getUser() );
+               $canUpload = $this->getTitle()->quickUserCan( 'upload', $this->getContext()->getUser() );
                if ( $canUpload && UploadBase::userCanReUpload(
                                $this->getContext()->getUser(),
                                $this->mPage->getFile()->name )