Skip to content

Commit 415ce72

Browse files
authored
fix: update property permissions and doc comments (#11)
1 parent 97808ce commit 415ce72

File tree

1 file changed

+8
-5
lines changed

1 file changed

+8
-5
lines changed

Sources/AmplifyUtilsNotifications/AUNotificationService.swift

+8-5
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,9 @@
88
import UserNotifications
99
import os.log
1010

11-
/// Attaches an image to a remote notification before it’s delivered to the user.
11+
/// Attaches a media (image, sound, or video) item to a remote notification before it’s delivered to the user.
1212
///
13-
/// The image will be downloaded from a URL specified in the incoming notification. The
13+
/// The media will be downloaded from a URL specified in the incoming notification. The
1414
/// format of the notification payload and name of the field containing the image URL is
1515
/// specified in payloadSchema, which conforms to AUNotificationPayload.
1616
open class AUNotificationService: UNNotificationServiceExtension {
@@ -20,7 +20,7 @@ open class AUNotificationService: UNNotificationServiceExtension {
2020
/// You can override the default value in the initializer of a child class.
2121
///
2222
/// Default: PinpointNotificationPayload
23-
open var payloadSchema: AUNotificationPayload.Type = PinpointNotificationPayload.self
23+
public var payloadSchema: AUNotificationPayload.Type = PinpointNotificationPayload.self
2424

2525
/// Function for retrieve data from remote URL.
2626
///
@@ -29,8 +29,11 @@ open class AUNotificationService: UNNotificationServiceExtension {
2929
/// Default: Data.init(contentsOf:options:)
3030
var loadDataFromURL: (URL) throws -> Data = { try Data(contentsOf: $0) }
3131

32-
var contentHandler: ((UNNotificationContent) -> Void)?
33-
var bestAttemptContent: UNMutableNotificationContent?
32+
/// The content handler for the notification.
33+
public var contentHandler: ((UNNotificationContent) -> Void)?
34+
35+
/// The content for the notification.
36+
public var bestAttemptContent: UNMutableNotificationContent?
3437

3538
/// Called when in incomming notification is received. Allows modification of the notification request before delivery.
3639
/// - Parameters:

0 commit comments

Comments
 (0)