Output pretty message on forbidden uploads

This commit is contained in:
Victor Vasiliev 2008-03-15 08:23:54 +00:00
parent a24d67e048
commit 20d85b52f9

View file

@ -14,6 +14,7 @@ class TitleBlacklistHooks {
public static function userCan( $title, $user, $action, &$result ) {
global $wgTitleBlacklist;
if( $action == 'create' || $action == 'edit' ) {
if( $title->getNamespace() == NS_IMAGE ) return true; //Should be handled using verifyUpload
efInitTitleBlacklist();
$blacklisted = $wgTitleBlacklist->isBlacklisted( $title, $action );
if( $blacklisted instanceof TitleBlacklistEntry ) {