vkaravir/a-plus — pull request #73 by Rubinous (2013-01-23 08:17:49+00:00)
Title: Bug fix - Trying to view someone else's submission page caused HTTP 500

- Edited Submission.check_user_permission to also allow users with User.is_staff to access the submission.

- Edited some comments in Submission.check_user_permission
- Denied access to view_submission from everyone else but the submitters of the submission because the view would make no sense to staff-like users.
- This also fixes the bug where the assignment of the index caused error in case anyone but the submitters of the submission tried to access this view.
- Added a comment about that to the code because check_user_permission might seem the right way to go