This repository has been archived on 2021-10-24. You can view files and clone it, but cannot push or open issues or pull requests.
greenlight/config/initializers/html5.rb

9 lines
347 B
Ruby

# frozen_string_literal: true
# Send a request to check if the HTML5 client is enabled on the BigBlueButton server.
uri = URI.parse(Rails.configuration.bigbluebutton_endpoint.gsub('bigbluebutton/api', 'html5client/check'))
res = Net::HTTP.get_response(uri)
# Set the HTML5 status.
Rails.application.config.html5_enabled = (res.code.to_i == 200)