Skip to content

Commit

Permalink
fix: enable authentication for Numbas
Browse files Browse the repository at this point in the history
  • Loading branch information
satikaj authored and ublefo committed Apr 15, 2024
1 parent 1c7ea73 commit 403cbfd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/api/numbas_api.rb
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ def stream_file_from_zip(zip_path, file_path)
params do
requires :task_def_id, type: Integer, desc: 'Task Definition ID to get Numbas test data for'
end
get '/numbas_api/:task_def_id/*file_path' do
get '/numbas_api/:task_def_id/:auth_token/:username/*file_path' do
env['api.format'] = :txt
task_def = TaskDefinition.find(params[:task_def_id])
if task_def.has_numbas_data?
Expand Down

0 comments on commit 403cbfd

Please sign in to comment.