Skip to content

Commit e29f131

Browse files
committed
Merge branch 'photo' of https://github.com/DaemonLab/Mess-Website into photo
2 parents 2e1ce3e + 9422add commit e29f131

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

qrscan/views.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ def mess_card(request):
3939

4040
picture = student.photo.url if student.photo else None
4141
try:
42-
if not picture and socialaccount_obj:
42+
if not picture and socialaccount_obj.exists():
4343
picture = socialaccount_obj[0].extra_data["picture"]
4444
except (IndexError, KeyError):
4545
picture = "not available"

0 commit comments

Comments
 (0)