summaryrefslogtreecommitdiff
path: root/bitbake/lib/bb/fetch/__init__.py
diff options
context:
space:
mode:
authorChris Larson <chris_larson@mentor.com>2010-04-12 08:14:11 -0700
committerRichard Purdie <rpurdie@linux.intel.com>2010-07-02 15:41:33 +0100
commit22a21799059b156d8858cbf32acb7c2aefb9a23b (patch)
tree1e0e83c86fe04e30576ddfb34577940596f8d809 /bitbake/lib/bb/fetch/__init__.py
parent1180bab54e2879401f3586c91a48174191a1ee8b (diff)
downloadopenembedded-core-22a21799059b156d8858cbf32acb7c2aefb9a23b.tar.gz
openembedded-core-22a21799059b156d8858cbf32acb7c2aefb9a23b.tar.bz2
openembedded-core-22a21799059b156d8858cbf32acb7c2aefb9a23b.tar.xz
openembedded-core-22a21799059b156d8858cbf32acb7c2aefb9a23b.zip
Kill unnecessary usages of the types module
types.IntType -> int types.StringType -> basestring ... Also moves our ImmutableTypes tuple into our own namespace. (Bitbake rev: 83674a3a5564ecb1f9d2c9b2d5b1eeb3c31272ab) Signed-off-by: Chris Larson <chris_larson@mentor.com> Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'bitbake/lib/bb/fetch/__init__.py')
-rw-r--r--bitbake/lib/bb/fetch/__init__.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/bitbake/lib/bb/fetch/__init__.py b/bitbake/lib/bb/fetch/__init__.py
index fec9c6ed7..f52b0acfc 100644
--- a/bitbake/lib/bb/fetch/__init__.py
+++ b/bitbake/lib/bb/fetch/__init__.py
@@ -126,8 +126,7 @@ def uri_replace(uri, uri_find, uri_replace, d):
for i in uri_find_decoded:
loc = uri_find_decoded.index(i)
result_decoded[loc] = uri_decoded[loc]
- import types
- if type(i) == types.StringType:
+ if isinstance(i, basestring):
if (re.match(i, uri_decoded[loc])):
result_decoded[loc] = re.sub(i, uri_replace_decoded[loc], uri_decoded[loc])
if uri_find_decoded.index(i) == 2: