Update application_controller.rb
This commit is contained in:
parent
9e666310cf
commit
59a3f792c6
@ -23,7 +23,20 @@ class ApplicationController < ActionController::Base
|
||||
/ToutiaoMicroApp/,
|
||||
/BytedanceWebview/,
|
||||
/ArkWeb/
|
||||
]
|
||||
],
|
||||
on_failure: -> (browser) {
|
||||
Rails.logger.warn <<~BROWSER_INFO
|
||||
Browser Blocked:
|
||||
User Agent: #{browser.ua}
|
||||
Name: #{browser.name}
|
||||
Version: #{browser.version}
|
||||
Platform: #{browser.platform.name}
|
||||
Device: #{browser.device.name}
|
||||
Mobile: #{browser.mobile?}
|
||||
Modern: #{browser.modern?}
|
||||
Bot: #{browser.bot?}
|
||||
BROWSER_INFO
|
||||
}
|
||||
before_action :set_locale
|
||||
before_action :log_browser_info
|
||||
after_action :track_action
|
||||
|
Loading…
Reference in New Issue
Block a user