File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -17,24 +17,22 @@ class NotificationService: UNNotificationServiceExtension {
1717 var change : Bool = false
1818
1919 var diffTime = Date ( ) . millisecondsSince1970 - NotificationService. lastRemoteNotifictionTS
20- print ( " noti:Tlast= \( NotificationService . lastRemoteNotifictionTS) " )
21- print ( " noti:Tnow= \( Date ( ) . millisecondsSince1970) " )
22- print ( " noti:Tdiff= \( diffTime) " )
23-
24- var lastTs = NotificationService . lastRemoteNotifictionTS
20+ // print("noti:Tlast=\(NotificationService.lastRemoteNotifictionTS)")
21+ // print("noti:Tnow=\(Date().millisecondsSince1970)")
22+ // print("noti:Tdiff=\(diffTime)")
2523
2624 // check if last notification was received less than 24 seconds ago
27- if ( diffTime < ( 24 * 1000 ) ) {
28- print ( " noti:change=true " )
25+ if ( diffTime < ( 25 * 1000 ) ) {
26+ // print("noti:change=true")
2927 change = true
3028 }
3129
3230 NotificationService . lastRemoteNotifictionTS = Date ( ) . millisecondsSince1970
3331
3432 if let bestAttemptContent = bestAttemptContent {
3533 if ( change) {
36- print ( " noti:actually changing " )
37- bestAttemptContent. title = " connecting ... ts= \( lastTs ) "
34+ // print("noti:actually changing")
35+ bestAttemptContent. title = " connecting ... "
3836 }
3937 contentHandler ( bestAttemptContent)
4038 }
You can’t perform that action at this time.
0 commit comments