Update 'apns2/credentials.py'

- fix backward compatibility issue
This commit is contained in:
2022-04-17 10:36:59 +03:00
parent 34fd0d0264
commit 3aeb5fe477
+1 -1
View File
@@ -64,7 +64,7 @@ class TokenCredentials(Credentials):
} }
jwt_token = jwt.encode(token_dict, self.__auth_key, jwt_token = jwt.encode(token_dict, self.__auth_key,
algorithm=self.__encryption_algorithm, algorithm=self.__encryption_algorithm,
headers=headers).decode('ascii') headers=headers)
# Cache JWT token for later use. One JWT token per connection. # Cache JWT token for later use. One JWT token per connection.
# https://developer.apple.com/documentation/usernotifications/setting_up_a_remote_notification_server/establishing_a_token-based_connection_to_apns # https://developer.apple.com/documentation/usernotifications/setting_up_a_remote_notification_server/establishing_a_token-based_connection_to_apns