Code Duplication    Length = 4-9 lines in 2 locations

_inc/lib/markdown/extra.php 2 locations

@@ 1067-1075 (lines=9) @@
1064
			$token =& $parts[1];
1065
			$text =& $parts[2];
1066
1067
			if (empty($token)) {
1068
				# Reached end of text span: empty stack without emitting.
1069
				# any more emphasis.
1070
				while ($token_stack[0]) {
1071
					$text_stack[1] .= array_shift($token_stack);
1072
					$text_stack[0] .= array_shift($text_stack);
1073
				}
1074
				break;
1075
			}
1076
1077
			$token_len = strlen($token);
1078
			if ($tree_char_em) {
@@ 1126-1129 (lines=4) @@
1123
			} else if ($token_len == 2) {
1124
				if ($strong) {
1125
					# Unwind any dangling emphasis marker:
1126
					if (strlen($token_stack[0]) == 1) {
1127
						$text_stack[1] .= array_shift($token_stack);
1128
						$text_stack[0] .= array_shift($text_stack);
1129
					}
1130
					# Closing strong marker:
1131
					array_shift($token_stack);
1132
					$span = array_shift($text_stack);