Commit 447c3f31 authored by ibuler's avatar ibuler

[Update] 修改一个bug

parent 59927ffc
......@@ -93,8 +93,6 @@ class Organization(models.Model):
@classmethod
def get_user_admin_orgs(cls, user):
if cls._user_admin_orgs and user.id in cls._user_admin_orgs:
return cls._user_admin_orgs[user.id]
admin_orgs = []
if user.is_anonymous:
return admin_orgs
......@@ -103,11 +101,6 @@ class Organization(models.Model):
admin_orgs.append(cls.default())
elif user.is_org_admin:
admin_orgs = user.admin_orgs.all()
if cls._user_admin_orgs is None:
cls._user_admin_orgs = {user.id: admin_orgs}
else:
cls._user_admin_orgs[user.id] = admin_orgs
return admin_orgs
@classmethod
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment