Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit f9b95d4

Browse files
committed
Patch #1768976, Fix for failing test_scriptpackages (untested but looks good)
1 parent e656869 commit f9b95d4

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

Lib/plat-mac/aetools.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@
2121
"""
2222

2323

24-
from types import *
2524
from Carbon import AE
2625
from Carbon import Evt
2726
from Carbon import AppleEvents
@@ -167,11 +166,11 @@ def __init__(self, signature=None, start=0, timeout=0):
167166
self.target_signature = None
168167
if signature is None:
169168
signature = self._signature
170-
if type(signature) == AEDescType:
169+
if isinstance(signature, AEDescType):
171170
self.target = signature
172171
elif hasattr(signature, '__aepack__'):
173172
self.target = signature.__aepack__()
174-
elif type(signature) == StringType and len(signature) == 4:
173+
elif isinstance(signature, str) and len(signature) == 4:
175174
self.target = AE.AECreateDesc(AppleEvents.typeApplSignature, signature)
176175
self.target_signature = signature
177176
else:

Misc/ACKS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -524,6 +524,7 @@ Steve Purcell
524524
Brian Quinlan
525525
Anders Qvist
526526
Burton Radons
527+
Antti Rasinen
527528
Eric Raymond
528529
Edward K. Ream
529530
Marc Recht

0 commit comments

Comments
 (0)