Code Duplication    Length = 4-9 lines in 2 locations

lib/markdown/markdown.php 2 locations

@@ 1236-1244 (lines=9) @@
1233
			$token =& $parts[1];
1234
			$text =& $parts[2];
1235
1236
			if (empty($token)) {
1237
				# Reached end of text span: empty stack without emitting.
1238
				# any more emphasis.
1239
				while ($token_stack[0]) {
1240
					$text_stack[1] .= array_shift($token_stack);
1241
					$text_stack[0] .= array_shift($text_stack);
1242
				}
1243
				break;
1244
			}
1245
1246
			$token_len = strlen($token);
1247
			if ($tree_char_em) {
@@ 1295-1298 (lines=4) @@
1292
			} else if ($token_len == 2) {
1293
				if ($strong) {
1294
					# Unwind any dangling emphasis marker:
1295
					if (strlen($token_stack[0]) == 1) {
1296
						$text_stack[1] .= array_shift($token_stack);
1297
						$text_stack[0] .= array_shift($text_stack);
1298
					}
1299
					# Closing strong marker:
1300
					array_shift($token_stack);
1301
					$span = array_shift($text_stack);