Method: Webhookdb::Platform.user_agent

Defined in:
lib/webhookdb/platform.rb

.user_agent(env) ⇒ Object

Return the user agent in the env. This should be the CLI user agent, though it may also be a browser in WASM depending on the browser.



23
24
25
26
# File 'lib/webhookdb/platform.rb', line 23

def self.user_agent(env)
  values = HEADERS.map { |h| env[h] }
  return values.find(&:present?) || ""
end