Skip to content
Snippets Groups Projects
Commit d8bfbe96 authored by Bianca Severino's avatar Bianca Severino
Browse files

Remove course_key from IDV SubmitPhotosView

parent 2711fbb3
Branches
Tags
No related merge requests found
......@@ -833,12 +833,8 @@ class SubmitPhotosView(View):
face_image (str): base64-encoded image data of the user's face.
photo_id_image (str): base64-encoded image data of the user's photo ID.
full_name (str): The user's full name, if the user is requesting a name change as well.
course_key (str): Identifier for the course, if initiated from a checkpoint.
checkpoint (str): Location of the checkpoint in the course.
"""
log.info((u"User {user_id} is submitting photos for ID verification").format(user_id=request.user.id))
# If the user already has an initial verification attempt, we can re-use the photo ID
# the user submitted with the initial attempt.
initial_verification = SoftwareSecurePhotoVerification.get_initial_verification(request.user)
......@@ -893,7 +889,6 @@ class SubmitPhotosView(View):
for param_name in [
"face_image",
"photo_id_image",
"course_key",
"full_name"
]
if param_name in request.POST
......@@ -923,14 +918,6 @@ class SubmitPhotosView(View):
log.error((u"User {user_id} missing required parameter face_image").format(user_id=request.user.id))
return None, HttpResponseBadRequest(msg)
# If provided, parse the course key and checkpoint location
if "course_key" in params:
try:
params["course_key"] = CourseKey.from_string(params["course_key"])
except InvalidKeyError:
log.error((u"User {user_id} provided invalid course_key").format(user_id=request.user.id))
return None, HttpResponseBadRequest(_("Invalid course key"))
return params, None
def _update_full_name(self, request, full_name):
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment