Code Duplication    Length = 9-9 lines in 2 locations

includes/FileDeleteForm.php 1 location

@@ 103-111 (lines=9) @@
100
			$deleteReasonList = $wgRequest->getText( 'wpDeleteReasonList' );
101
			$deleteReason = $wgRequest->getText( 'wpReason' );
102
103
			if ( $deleteReasonList == 'other' ) {
104
				$reason = $deleteReason;
105
			} elseif ( $deleteReason != '' ) {
106
				// Entry from drop down menu + additional comment
107
				$reason = $deleteReasonList . wfMessage( 'colon-separator' )
108
					->inContentLanguage()->text() . $deleteReason;
109
			} else {
110
				$reason = $deleteReasonList;
111
			}
112
113
			$status = self::doDelete(
114
				$this->title,

includes/page/Article.php 1 location

@@ 1672-1680 (lines=9) @@
1669
		$deleteReasonList = $request->getText( 'wpDeleteReasonList', 'other' );
1670
		$deleteReason = $request->getText( 'wpReason' );
1671
1672
		if ( $deleteReasonList == 'other' ) {
1673
			$reason = $deleteReason;
1674
		} elseif ( $deleteReason != '' ) {
1675
			// Entry from drop down menu + additional comment
1676
			$colonseparator = wfMessage( 'colon-separator' )->inContentLanguage()->text();
1677
			$reason = $deleteReasonList . $colonseparator . $deleteReason;
1678
		} else {
1679
			$reason = $deleteReasonList;
1680
		}
1681
1682
		if ( $request->wasPosted() && $user->matchEditToken( $request->getVal( 'wpEditToken' ),
1683
			[ 'delete', $this->getTitle()->getPrefixedText() ] )