diff --git a/login/models.py b/login/models.py index 710f69bce452cbad3bc711a72ee93c8095d8ba20..f69d75abc0ccc0ba627d0856d5321e28b42220ec 100644 --- a/login/models.py +++ b/login/models.py @@ -104,7 +104,7 @@ class User(db.Model): @staticmethod def get_recovery_link(api, kratos_id): - """Queries Kratos to find kratos ID for this given identifier + """Call the kratos API to create a recovery URL for a kratos ID :param: api Kratos ADMIN API Object :param: kratos_id UUID of kratos object :return: Return none or string with recovery URL @@ -148,7 +148,7 @@ class User(db.Model): cookie_csrf = search.group(1) if not cookie_csrf or not cookie_session: - raise Exception("Flow started, but expected cookies not found") + raise BackendError("Flow started, but expected cookies not found") # Combined the relevant cookies cookie = cookie_csrf + "; " + cookie_session