Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
iv
erp5
Commits
9187326b
Commit
9187326b
authored
Dec 06, 2016
by
iv
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ERP5Workflow: PERF: improve folder's objectValues
by using list comprehension instead of filter
parent
d844e9af
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
2 deletions
+1
-2
product/ERP5Type/Core/Folder.py
product/ERP5Type/Core/Folder.py
+1
-2
No files found.
product/ERP5Type/Core/Folder.py
View file @
9187326b
...
@@ -1537,8 +1537,7 @@ class Folder(CopyContainer, CMFBTreeFolder, CMFHBTreeFolder, Base, FolderMixIn):
...
@@ -1537,8 +1537,7 @@ class Folder(CopyContainer, CMFBTreeFolder, CMFHBTreeFolder, Base, FolderMixIn):
if
portal_type
is
not
None
:
if
portal_type
is
not
None
:
if
isinstance
(
portal_type
,
str
):
if
isinstance
(
portal_type
,
str
):
portal_type
=
(
portal_type
,)
portal_type
=
(
portal_type
,)
object_list
=
filter
(
lambda
x
:
x
.
getPortalType
()
in
portal_type
,
object_list
=
[
o
for
o
in
object_list
if
o
.
getPortalType
()
in
portal_type
]
object_list
)
if
checked_permission
is
not
None
:
if
checked_permission
is
not
None
:
checkPermission
=
getSecurityManager
().
checkPermission
checkPermission
=
getSecurityManager
().
checkPermission
object_list
=
[
o
for
o
in
object_list
object_list
=
[
o
for
o
in
object_list
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment