* Security fix for API on MSIE
* (bug 12768) Database query syntax error in maintenance/storage/compressOld.inc
* (bug 12753) Empty captions in MediaWiki:Sidebar result in PHP errors
+* (bug 12790) Page protection is not logged when edit-protection is used and move-protection is not
== Parser changes in 1.12 ==
$comment .= "$expiry_description";
if ( $cascade )
$comment .= "$cascade_description";
-
+
+ $rowsAffected = false;
# Update restrictions table
foreach( $limit as $action => $restrictions ) {
if ($restrictions != '' ) {
array( 'pr_page' => $id, 'pr_type' => $action
, 'pr_level' => $restrictions, 'pr_cascade' => $cascade ? 1 : 0
, 'pr_expiry' => $encodedExpiry ), __METHOD__ );
+ if($dbw->affectedRows() != 0)
+ $rowsAffected = true;
} else {
$dbw->delete( 'page_restrictions', array( 'pr_page' => $id,
'pr_type' => $action ), __METHOD__ );
+ if($dbw->affectedRows() != 0)
+ $rowsAffected = true;
}
}
- if($dbw->affectedRows() == 0)
+ if(!$rowsAffected)
// No change
return true;
# Update the protection log
$log = new LogPage( 'protect' );
+
+
if( $protect ) {
$log->addEntry( $modified ? 'modify' : 'protect', $this->mTitle, trim( $reason . " [$updated]$cascade_description$expiry_description" ) );