code: protected static function validateTimeZone($timeZone)
      {
          if (is_object($timeZone) && $timeZone instanceof DateTimeZone) {
              return $timeZone;
          } elseif (is_string($timeZone)) {
              return new DateTimeZone($timeZone);
          }
  
          throw new \Exception('Invalid timezone');
      }
docs: Validate a timezone.
  
  @param DateTimeZone|string $timeZone The timezone to validate, either as a timezone string or object
  
  @throws \Exception
  
  @return DateTimeZone The timezone as a timezone object
  @return DateTimeZone The timezone as a timezone object