Code Duplication    Length = 2-2 lines in 2 locations

Sources/Subs-Calendar.php 2 locations

@@ 1366-1367 (lines=2) @@
1363
	// Define the timezone for this event, falling back to the default if not provided
1364
	if (!empty($eventOptions['tz']) && in_array($eventOptions['tz'], timezone_identifiers_list(DateTimeZone::ALL_WITH_BC)))
1365
		$tz = $eventOptions['tz'];
1366
	elseif (!empty($_POST['tz']) && in_array($_POST['tz'], timezone_identifiers_list(DateTimeZone::ALL_WITH_BC)))
1367
		$tz = $_POST['tz'];
1368
	else
1369
		$tz = getUserTimezone();
1370
@@ 1660-1661 (lines=2) @@
1657
		$smcFunc['db_free_result']($request);
1658
	}
1659
1660
	if (empty($timezone) || !in_array($timezone, timezone_identifiers_list(DateTimeZone::ALL_WITH_BC)))
1661
		$timezone = isset($modSettings['default_timezone']) ? $modSettings['default_timezone'] : date_default_timezone_get();
1662
1663
	return $timezone;
1664
}