summaryrefslogtreecommitdiff
path: root/examples
diff options
context:
space:
mode:
authorThomas Haller <thaller@redhat.com>2014-10-31 16:34:23 +0100
committerThomas Haller <thaller@redhat.com>2014-10-31 16:39:00 +0100
commit0923769285ba6e5f665a3c9b5f01b17d1be34d5b (patch)
tree788e589e2261440af5a5f3527bb8d80bfc3d3283 /examples
parent4f9e2e960372fa116931bcc06563a9c3c638dbd7 (diff)
downloadNetworkManager-0923769285ba6e5f665a3c9b5f01b17d1be34d5b.tar.gz
test,examples: fix scripts to avoid 'has_key' for Python 3
'has_key' on Dictionaries is removed from Python3 in favor of 'in'. Signed-off-by: Thomas Haller <thaller@redhat.com>
Diffstat (limited to 'examples')
-rwxr-xr-xexamples/python/dbus/update-ip4-method.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/python/dbus/update-ip4-method.py b/examples/python/dbus/update-ip4-method.py
index 243738c5c8..bf14f7f9cc 100755
--- a/examples/python/dbus/update-ip4-method.py
+++ b/examples/python/dbus/update-ip4-method.py
@@ -58,7 +58,7 @@ for c_path in settings.ListConnections():
continue
# add IPv4 setting if it doesn't yet exist
- if not c_settings.has_key('ipv4'):
+ if 'ipv4' not in c_settings:
c_settings['ipv4'] = {}
# set the method and change properties