Skip to content

Commit 6f69855

Browse files
committed
feat(osf): ENG-11734 add DownloadEvent model and migration with dashboard access group
1 parent 3068762 commit 6f69855

1 file changed

Lines changed: 2 additions & 5 deletions

File tree

osf/migrations/0045_downloadevent.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,8 @@ def create_dashboard_group(apps, schema_editor):
2222
Group = apps.get_model('auth', 'Group')
2323
OSFUser = apps.get_model('osf', 'OSFUser')
2424
group, _ = Group.objects.get_or_create(name=DASHBOARD_GROUP_NAME)
25-
for identifier in DASHBOARD_USERS:
26-
user = (
27-
OSFUser.objects.filter(username=identifier).first()
28-
or OSFUser.objects.filter(guids___id=identifier).first()
29-
)
25+
for username in DASHBOARD_USERS:
26+
user = OSFUser.objects.filter(username=username).first()
3027
if user:
3128
group.user_set.add(user)
3229

0 commit comments

Comments
 (0)