Code Duplication    Length = 9-11 lines in 2 locations

includes/specials/SpecialUndelete.php 1 location

@@ 1052-1060 (lines=9) @@
1049
		}
1050
1051
		if ( $rev->isDeleted( Revision::DELETED_TEXT ) ) {
1052
			if ( !$rev->userCan( Revision::DELETED_TEXT, $user ) ) {
1053
				$out->wrapWikiMsg(
1054
					"<div class='mw-warning plainlinks'>\n$1\n</div>\n",
1055
				$rev->isDeleted( Revision::DELETED_RESTRICTED ) ?
1056
					'rev-suppressed-text-permission' : 'rev-deleted-text-permission'
1057
				);
1058
1059
				return;
1060
			}
1061
1062
			$out->wrapWikiMsg(
1063
				"<div class='mw-warning plainlinks'>\n$1\n</div>\n",

includes/EditPage.php 1 location

@@ 2946-2956 (lines=11) @@
2943
				if ( $revision ) {
2944
					// Let sysop know that this will make private content public if saved
2945
2946
					if ( !$revision->userCan( Revision::DELETED_TEXT, $wgUser ) ) {
2947
						$wgOut->wrapWikiMsg(
2948
							"<div class='mw-warning plainlinks'>\n$1\n</div>\n",
2949
							'rev-deleted-text-permission'
2950
						);
2951
					} elseif ( $revision->isDeleted( Revision::DELETED_TEXT ) ) {
2952
						$wgOut->wrapWikiMsg(
2953
							"<div class='mw-warning plainlinks'>\n$1\n</div>\n",
2954
							'rev-deleted-text-view'
2955
						);
2956
					}
2957
2958
					if ( !$revision->isCurrent() ) {
2959
						$this->mArticle->setOldSubtitle( $revision->getId() );