Recaptcha.configure do |config|
config.site_key = Rails.application.credentials.dig(:google_recaptcha, :site_key)
config.secret_key = Rails.application.credentials.dig(:google_recaptcha, :secret_key)
# Uncomment the following line if you are using a proxy server:
# config.proxy = 'http://myproxy.com.au:8080'
# Uncomment the following lines if you are using the Enterprise API:
# config.enterprise = true
# config.enterprise_api_key = 'AIzvFyE3TU-g4K_Kozr9F1smEzZSGBVOfLKyupA'
# config.enterprise_project_id = 'my-project'
end
1条答案
按热度按时间r6hnlfcb1#
我想你是错过了gem,添加这一行到Gemfile然后运行
bundle install
字符串
然后用这些内容创建初始化器文件
型
把这个加到你的苗条档案里
型
这个应该能用