Fix Runner access for programming groups

* We also rename the corresponding columns in the Runner model, so that for polymorphic association gets clear.
This commit is contained in:
Sebastian Serth
2023-08-20 20:32:41 +02:00
committed by Sebastian Serth
parent 977fa4539e
commit a1941336d9
8 changed files with 36 additions and 25 deletions

View File

@ -15,7 +15,7 @@ class LiveStreamsController < ApplicationController
redirect_back(fallback_location: root_path, allow_other_host: true, alert: t('exercises.download_file_tree.gone'))
else
desired_file = params[:filename].to_s
runner = Runner.for(current_user, @submission.exercise.execution_environment)
runner = Runner.for(current_contributor, @submission.exercise.execution_environment)
fallback_location = implement_exercise_path(@submission.exercise)
send_runner_file(runner, desired_file, fallback_location)
end