The problem here is that this chunk of code is triggered when we send a request to "/change_enrollment" and pass in the course_id in the request body.  This means that the middleware that throws the course info into the context can't actually detect the course_id in question since it is not present in the URL.

I see a couple of options:

1. We let the course_id stuff in the context just be all empty, and throw the course info into the "data" for these enrollment events.
2. We do what I've done here, which is basically override the context with the course info extracted from the request.

I'm fine with either one... the more I think about it, the more I'm leaning toward the first option though.