Skip to content

Commit

Permalink
fix(misc): import teacher photos should only find staff
Browse files Browse the repository at this point in the history
  • Loading branch information
NotFish232 committed Dec 11, 2024
1 parent f80a619 commit a7ab927
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def handle(self, *args, **options):
if IS_STAFF:
if "-" in path.stem:
last_name, first_name = path.stem.rsplit("-", 1)
user = get_user_model().objects.filter(first_name=first_name, last_name=last_name).first()
user = get_user_model().objects.filter(first_name=first_name, last_name=last_name, user_type__in=["teacher", "counselor"]).first()
else:
try:
int(path.stem)
Expand Down

0 comments on commit a7ab927

Please sign in to comment.