Code Duplication    Length = 4-4 lines in 2 locations

includes/EditPage.php 2 locations

@@ 1365-1368 (lines=4) @@
1362
1363
		$title = Title::newFromText( $preload );
1364
		# Check for existence to avoid getting MediaWiki:Noarticletext
1365
		if ( $title === null || !$title->exists() || !$title->userCan( 'read', $wgUser ) ) {
1366
			// TODO: somehow show a warning to the user!
1367
			return $handler->makeEmptyContent();
1368
		}
1369
1370
		$page = WikiPage::factory( $title );
1371
		if ( $page->isRedirect() ) {
@@ 1374-1377 (lines=4) @@
1371
		if ( $page->isRedirect() ) {
1372
			$title = $page->getRedirectTarget();
1373
			# Same as before
1374
			if ( $title === null || !$title->exists() || !$title->userCan( 'read', $wgUser ) ) {
1375
				// TODO: somehow show a warning to the user!
1376
				return $handler->makeEmptyContent();
1377
			}
1378
			$page = WikiPage::factory( $title );
1379
		}
1380