diff --git a/karaage/common/aaf_rapid_connect.py b/karaage/common/aaf_rapid_connect.py
index <HASH>..<HASH> 100644
--- a/karaage/common/aaf_rapid_connect.py
+++ b/karaage/common/aaf_rapid_connect.py
@@ -32,6 +32,9 @@ def build_login_url(request, entityid=None):
 def get_institute_from_token(verified_jwt):
     attrs = verified_jwt['https://aaf.edu.au/attributes']
     value_list = attrs['edupersonscopedaffiliation'].split(";")
+    value_list = [
+        item for item in value_list if item
+    ]
     try:
         institute = Institute.objects.get(
             saml_scoped_affiliation__in=value_list
Ensure we don't accidentally match institute based on empty stringt

Change-Id: I7e<I>bde7df<I>f<I>a6c2cf2fe0a4deae