Skip to content

Commit e010062

Browse files
Swapped the definitions for VAPID and its fully qualified name so the fully qualified one is the type alias
1 parent 1d97d23 commit e010062

File tree

4 files changed

+8
-8
lines changed

4 files changed

+8
-8
lines changed

Sources/WebPush/Subscriber.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@ public protocol SubscriberProtocol: Sendable {
2323

2424
/// The preferred VAPID Key ID to use, if available.
2525
///
26-
/// If unknown, use the key set to ``VoluntaryApplicationServerIdentification/Configuration/primaryKey``, but be aware that this may be different from the key originally used at time of subscription, and if it is, push messages will be rejected.
26+
/// If unknown, use the key set to ``VAPID/Configuration/primaryKey``, but be aware that this may be different from the key originally used at time of subscription, and if it is, push messages will be rejected.
2727
///
28-
/// - Important: It is highly recommended to store the VAPID Key ID used at time of registration with the subscriber, and always supply the key itself to the manager. If you are phasing out the key and don't want new subscribers registered against it, store the key in ``VoluntaryApplicationServerIdentification/Configuration/deprecatedKeys``, otherwise store it in ``VoluntaryApplicationServerIdentification/Configuration/keys``.
28+
/// - Important: It is highly recommended to store the VAPID Key ID used at time of registration with the subscriber, and always supply the key itself to the manager. If you are phasing out the key and don't want new subscribers registered against it, store the key in ``VAPID/Configuration/deprecatedKeys``, otherwise store it in ``VAPID/Configuration/keys``.
2929
var vapidKeyID: VAPID.Key.ID { get }
3030
}
3131

Sources/WebPush/VAPID/VAPID.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@
88

99
import Foundation
1010

11-
public typealias VAPID = VoluntaryApplicationServerIdentification
11+
public typealias VoluntaryApplicationServerIdentification = VAPID
1212

1313
/// A set of types for Voluntary Application Server Identification, also known as VAPID.
1414
///
15-
/// - SeeAlso: [RFC 8292](https://datatracker.ietf.org/doc/html/rfc8292)
16-
public enum VoluntaryApplicationServerIdentification: Sendable {}
15+
/// - SeeAlso: [RFC 8292 Voluntary Application Server Identification (VAPID) for Web Push](https://datatracker.ietf.org/doc/html/rfc8292)
16+
public enum VAPID: Sendable {}

Sources/WebPush/VAPID/VAPIDConfiguration.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ extension VoluntaryApplicationServerIdentification {
3131
/// The VAPID key that identifies the push service to subscribers.
3232
///
3333
/// If not provided, a key from ``keys`` will be used instead.
34-
/// - SeeAlso: ``VoluntaryApplicationServerIdentification/Configuration``
34+
/// - SeeAlso: ``VAPID/Configuration``
3535
public private(set) var primaryKey: Key?
3636

3737
/// The set of valid keys to choose from when identifying the applications erver to new registrations.

Sources/WebPush/VAPID/VAPIDKey.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import Foundation
1212
extension VoluntaryApplicationServerIdentification {
1313
/// Represents the application server's identification key that is used to confirm to a push service that the server connecting to it is the same one that was subscribed to.
1414
///
15-
/// When sharing with the browser, ``VoluntaryApplicationServerIdentification/Key/ID`` can be used.
15+
/// When sharing with the browser, ``VAPID/Key/ID`` can be used.
1616
public struct Key: Sendable {
1717
private var privateKey: P256.Signing.PrivateKey
1818

@@ -62,7 +62,7 @@ extension VAPID.Key: Codable {
6262
}
6363

6464
extension VAPID.Key: Identifiable {
65-
/// The identifier for a private ``VoluntaryApplicationServerIdentification/Key``'s public key.
65+
/// The identifier for a private ``VAPID/Key``'s public key.
6666
///
6767
/// This value can be shared as is with a subscription registration as the `applicationServerKey` key in JavaScript.
6868
///

0 commit comments

Comments
 (0)