perf: 修改应用授权树,没有的时候不显示

pull/6950/head
ibuler 2021-09-24 13:57:20 +08:00 committed by Jiangjie.Bai
parent 90d269d2a2
commit 08cd91c426
1 changed files with 2 additions and 0 deletions

View File

@ -32,6 +32,8 @@ class SerializeApplicationToTreeNodeMixin:
return node
def serialize_applications_with_org(self, applications):
if not applications:
return []
root_node = self.create_root_node()
tree_nodes = [root_node]
organizations = self.filter_organizations(applications)