Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also 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: pitiphong-p/URLQueryItemEncoder
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: master
Choose a base ref
...
head repository: Storytel/URLQueryItemEncoder
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
  • 1 commit
  • 1 file changed
  • 1 contributor

Commits on Feb 22, 2022

  1. Added support for WatchOS

    salling committed Feb 22, 2022
    Copy the full SHA
    3f184d9 View commit details
Showing with 2 additions and 1 deletion.
  1. +2 −1 URLQueryItemEncoder/URLQueryItemEncoder.swift
3 changes: 2 additions & 1 deletion URLQueryItemEncoder/URLQueryItemEncoder.swift
Original file line number Diff line number Diff line change
@@ -14,6 +14,7 @@ protocol URLQueryItemEncoderDateFormatter {
}

extension DateFormatter: URLQueryItemEncoderDateFormatter {}
@available(watchOS 3.0, *)
@available(iOS 10.0, iOSApplicationExtension 10.0, macOS 10.12, *)
extension ISO8601DateFormatter: URLQueryItemEncoderDateFormatter {}

@@ -25,7 +26,7 @@ let iso8601Formatter: URLQueryItemEncoderDateFormatter = {
formatter.dateFormat = "yyyy-MM-dd'T'HH:mm:ss.SSS'Z'"
return formatter
#else
if #available(iOS 11.0, macOS 10.13, *) {
if #available(iOS 11.0, macOS 10.13, *), #available(watchOS 4.0, *) {
var formatter = ISO8601DateFormatter()
formatter.formatOptions.formUnion([.withFractionalSeconds])
return formatter