Code Duplication    Length = 5-7 lines in 2 locations

Sources/ShowAttachments.php 1 location

@@ 43-47 (lines=5) @@
40
41
	if (!empty($modSettings['enableCompressedOutput']) && !headers_sent() && ob_get_length() == 0)
42
	{
43
		if (@ini_get('zlib.output_compression') == '1' || @ini_get('output_handler') == 'ob_gzhandler')
44
			$modSettings['enableCompressedOutput'] = 0;
45
46
		else
47
			ob_start('ob_gzhandler');
48
	}
49
50
	if (empty($modSettings['enableCompressedOutput']))

index.php 1 location

@@ 95-101 (lines=7) @@
92
if (!empty($modSettings['enableCompressedOutput']) && !headers_sent())
93
{
94
	// If zlib is being used, turn off output compression.
95
	if (ini_get('zlib.output_compression') >= 1 || ini_get('output_handler') == 'ob_gzhandler')
96
		$modSettings['enableCompressedOutput'] = '0';
97
	else
98
	{
99
		ob_end_clean();
100
		ob_start('ob_gzhandler');
101
	}
102
}
103
104
/**