From 1a98f75260289f72d430abef026c6da2b1d5a255 Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Tue, 23 Aug 2011 14:00:54 -0700 Subject: [PATCH] ovs.db.types: Use .append instead of += for adding to lists. Python does not do a good job of appending lists to lists. Suggested-by: Reid Price --- python/ovs/db/types.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/python/ovs/db/types.py b/python/ovs/db/types.py index 635922f5..f7bc2482 100644 --- a/python/ovs/db/types.py +++ b/python/ovs/db/types.py @@ -510,14 +510,14 @@ class Type(object): keyConstraints = self.key.constraintsToEnglish(escapeLiteral) if keyConstraints: if self.value: - constraints += ['key ' + keyConstraints] + constraints.append('key %s' % keyConstraints) else: - constraints += [keyConstraints] + constraints.append(keyConstraints) if self.value: valueConstraints = self.value.constraintsToEnglish(escapeLiteral) if valueConstraints: - constraints += ['value ' + valueConstraints] + constraints.append('value %s' % valueConstraints) return ', '.join(constraints) -- 2.30.2