Skip to content

Commit

Permalink
Deprecated .sandbox in favor of .development
Browse files Browse the repository at this point in the history
  • Loading branch information
dimitribouniol committed May 7, 2024
1 parent 3164935 commit 698fa93
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ let client = APNSClient(
keyIdentifier: keyIdentifier,
teamIdentifier: teamIdentifier
),
environment: .sandbox
environment: .development
),
eventLoopGroupProvider: .createNew,
responseDecoder: JSONDecoder(),
Expand Down
2 changes: 1 addition & 1 deletion Sources/APNS/APNS.docc/APNSwift.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ let client = APNSClient(
keyIdentifier: keyIdentifier,
teamIdentifier: teamIdentifier
),
environment: .sandbox
environment: .development
),
eventLoopGroupProvider: .createNew,
responseDecoder: JSONDecoder(),
Expand Down
6 changes: 5 additions & 1 deletion Sources/APNSCore/APNSEnvironment.swift
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,11 @@ public struct APNSEnvironment: Sendable {
public static let production = Self(url: "https://api.push.apple.com", port: 443)

/// The sandbox APNs environment.
public static let sandbox = Self(url: "https://api.development.push.apple.com", port: 443)
@available(*, deprecated, renamed: "development")
public static let sandbox = development

/// The development APNs environment.
public static let development = Self(url: "https://api.development.push.apple.com", port: 443)

/// Creates an APNs environment with a custom URL.
///
Expand Down
2 changes: 1 addition & 1 deletion Sources/APNSExample/Program.swift
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ struct Main {
keyIdentifier: keyIdentifier,
teamIdentifier: teamIdentifier
),
environment: .sandbox
environment: .development
),
eventLoopGroupProvider: .createNew,
responseDecoder: JSONDecoder(),
Expand Down
2 changes: 1 addition & 1 deletion Tests/APNSTests/APNSClientTests.swift
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ final class APNSClientTests: XCTestCase {
keyIdentifier: "MY_KEY_ID",
teamIdentifier: "MY_TEAM_ID"
),
environment: .sandbox
environment: .development
),
eventLoopGroupProvider: .createNew,
responseDecoder: JSONDecoder(),
Expand Down

0 comments on commit 698fa93

Please sign in to comment.