Skip to content
Permalink

Comparing changes

This is a direct comparison between two commits made in this repository or its related repositories. View the default comparison for this range or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: aws/aws-sdk-php
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: baa6f770dd9c7d96e87648f29f20ecea7f9dca7c
Choose a base ref
..
head repository: aws/aws-sdk-php
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: d821673f6088a99ee7d1e64c04155d373c6a78c0
Choose a head ref
Showing with 3 additions and 3 deletions.
  1. +1 −1 .changes/nextrelease/iso-8601-fix.json
  2. +2 −2 src/Api/DateTimeResult.php
2 changes: 1 addition & 1 deletion .changes/nextrelease/iso-8601-fix.json
Original file line number Diff line number Diff line change
@@ -4,4 +4,4 @@
"category": "Api",
"description": "Fixes issue with parsing iso8601 timestamps with nanosecond precision in versions 8.0.9 and below."
}
]
]
4 changes: 2 additions & 2 deletions src/Api/DateTimeResult.php
Original file line number Diff line number Diff line change
@@ -62,8 +62,8 @@ public static function fromISO8601($iso8601Timestamp)
throw new ParserException('Invalid timestamp value passed to DateTimeResult::fromISO8601');
}

//Prior to 8.0.10, nanosecond precision is not supported
// Trims nanoseconds, if present, for affected version ranges
// Prior to 8.0.10, nanosecond precision is not supported
// Reduces to microsecond precision if nanosecond precision is detected
if (PHP_VERSION_ID < 80010
&& preg_match(self::ISO8601_NANOSECOND_REGEX, $iso8601Timestamp, $matches)
) {