Add NotificationPushRuleType.pushRuleId

This commit is contained in:
Alfonso Grillo
2023-02-02 15:18:52 +01:00
parent e3573942d7
commit ddc268b01e
3 changed files with 14 additions and 8 deletions
@@ -21,3 +21,9 @@ protocol NotificationPushRuleType {
var enabled: Bool { get }
func matches(standardActions: NotificationStandardActions?) -> Bool
}
extension NotificationPushRuleType {
var pushRuleId: NotificationPushRuleId? {
ruleId.flatMap(NotificationPushRuleId.init(rawValue:))
}
}