Use list comprehension
This commit is contained in:
parent
a059afa9ce
commit
bbc2855cc5
@ -165,9 +165,7 @@ class relation (object):
|
|||||||
raise Exception('Invalid attributes for projection')
|
raise Exception('Invalid attributes for projection')
|
||||||
newt = relation()
|
newt = relation()
|
||||||
# Create the header
|
# Create the header
|
||||||
h = []
|
h = [self.header.attributes[i] for i in ids]
|
||||||
for i in ids:
|
|
||||||
h.append(self.header.attributes[i])
|
|
||||||
newt.header = header(h)
|
newt.header = header(h)
|
||||||
|
|
||||||
# Create the body
|
# Create the body
|
||||||
|
Loading…
x
Reference in New Issue
Block a user