Use generator expression to instanciate BrowseRecordList instead of list comprehensions
This commit is contained in:
1 parent
6aec5c64ab
commit
010ebcc33e
1 file changed
+2
-2
@@ -509,8 +509,8 @@ class ModelStorage(Model):
|
||||
if isinstance(ids, (int, long)):
|
||||
return BrowseRecord(cursor, user, ids, self, context=context)
|
||||
local_cache = {}
|
||||
return BrowseRecordList([BrowseRecord(cursor, user, x, self,
|
||||
local_cache=local_cache, context=context) for x in ids],
|
||||
return BrowseRecordList((BrowseRecord(cursor, user, x, self,
|
||||
local_cache=local_cache, context=context) for x in ids),
|
||||
context=context)
|
||||
|
||||
def __export_row(self, cursor, user, row, fields_names, context=None):
|
||||
|
||||
Reference in new issue
Block a user