* Do not allow working on Special:EditWatchlist
* Do not reset all notification markers
* Do not delete expired restrictions
Change-Id: I7a990c0a80b9c7a6340465dd082a110dafea8f14
* Purge expired restrictions from the page_restrictions table
*/
static function purgeExpiredRestrictions() {
* Purge expired restrictions from the page_restrictions table
*/
static function purgeExpiredRestrictions() {
+ if ( wfReadOnly() ) {
+ return;
+ }
+
$dbw = wfGetDB( DB_MASTER );
$dbw->delete(
'page_restrictions',
$dbw = wfGetDB( DB_MASTER );
$dbw->delete(
'page_restrictions',
* the next change of any watched page.
*/
public function clearAllNotifications() {
* the next change of any watched page.
*/
public function clearAllNotifications() {
+ if ( wfReadOnly() ) {
+ return;
+ }
+
global $wgUseEnotif, $wgShowUpdatedMarker;
if ( !$wgUseEnotif && !$wgShowUpdatedMarker ) {
$this->setNewtalk( false );
global $wgUseEnotif, $wgShowUpdatedMarker;
if ( !$wgUseEnotif && !$wgShowUpdatedMarker ) {
$this->setNewtalk( false );
}
$this->checkPermissions();
}
$this->checkPermissions();
+ $this->checkReadOnly();