public static function getTimeZoneObject($tz, $ignoreDst = false)
	{
		// If the time zone object is not set, attempt to build it.
		if (!($tz instanceof DateTimeZone))
		{
			if ($tz === null)
			{
				$tz = self::$gmt;
			}
			elseif (is_numeric($tz))
			{
				// Translate from offset.
				$tz = new DateTimeZone(self::$offsets[(string) $tz]);
			}
			elseif (is_string($tz))
			{
				$tz = new DateTimeZone($tz);
			}
		}

		if ($ignoreDst)
		{
			$lastYear = self::of('-1 year')->toUnix();
			$currentDate = self::of('now')->toUnix();
			$transitions = $tz->getTransitions($lastYear, $currentDate);
			$offsets = array_reduce($transitions, function($carry, $transition){
				if (empty($transition['isdst']))
				{
					$carry[] = $transition['offset'];
				}
				return $carry;
			});

			if (!empty($offsets))
			{
				$offset = $offsets[0];
				if (abs($offset) > 0)
				{
					// convert seconds to hours
					$offset = $offset / 3600;
				}
				$tz = new DateTimeZone($offset);
			}
		}
		return $tz;
	}