Description/Context
The is_instructor method here is getting called for multiple assignments redundantly. Since is_instructor is checking the current user's permission. It should be called once at start.
Plan/Design
We should move it outside the loop and call it only once to avoid redundantly calling for all the submission items.