From eb406b3111d1aef7c92baef66b035dc427e1d5cd Mon Sep 17 00:00:00 2001 From: Mariam A Date: Thu, 20 Jun 2024 08:07:37 -0400 Subject: [PATCH] LTI-383: remove hard coded BBB param prefix (#328) --- app/controllers/concerns/bbb_helper.rb | 2 +- app/controllers/rooms_controller.rb | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/app/controllers/concerns/bbb_helper.rb b/app/controllers/concerns/bbb_helper.rb index c21ec3f7..1323f9cd 100644 --- a/app/controllers/concerns/bbb_helper.rb +++ b/app/controllers/concerns/bbb_helper.rb @@ -293,7 +293,7 @@ def add_ext_params(action, options) @chosen_room.settings['ext_params']&.[](action)&.each do |key, value| # the value in ext_params from the tenant settings is the name that should be passed to BBB bbb_name = ext_params&.[](action)&.[](key) - options["userdata-#{bbb_name}"] = value if bbb_name + options[bbb_name] = value if bbb_name end end end diff --git a/app/controllers/rooms_controller.rb b/app/controllers/rooms_controller.rb index 65a039c3..7eadc2ae 100644 --- a/app/controllers/rooms_controller.rb +++ b/app/controllers/rooms_controller.rb @@ -529,6 +529,8 @@ def set_ext_params broker_ext_params = tenant_setting(tenant, 'ext_params') lms_custom_params = launch_request_params['message']['custom_params'] + logger.debug("[Rooms\'s Controller] extra params from broker: #{broker_ext_params} \n custom params from lms: #{lms_custom_params}") + pass_on_join_params = lms_custom_params.select { |k, _| broker_ext_params&.[]('join')&.key?(k) } pass_on_create_params = lms_custom_params.select { |k, _| broker_ext_params&.[]('create')&.key?(k) }