mirror of
https://github.com/Sneed-Group/pypush-plus-plus
synced 2024-12-23 11:22:42 -06:00
Iterate over references instead of indexes for identities
This commit is contained in:
parent
855390ec43
commit
04969a0160
1 changed files with 3 additions and 3 deletions
|
@ -103,9 +103,9 @@ class APNSProxy:
|
|||
|
||||
# Replace public keys
|
||||
for r in resp["results"].keys():
|
||||
for i in range(len(resp["results"][r]["identities"])):
|
||||
if "client-data" in resp["results"][r]["identities"][i]:
|
||||
resp["results"][r]["identities"][i]["client-data"]["public-message-identity-key"] = b"REDACTED"
|
||||
for identity in resp["results"][r]["identities"]:
|
||||
if "client-data" in identity:
|
||||
identity["client-data"]["public-message-identity-key"] = b"REDACTED"
|
||||
|
||||
resp = gzip.compress(plistlib.dumps(resp, fmt=plistlib.FMT_BINARY), mtime=0)
|
||||
body["b"] = resp
|
||||
|
|
Loading…
Reference in a new issue