Module: Roda::RodaPlugins::Heartbeat::InstanceMethods

Defined in:
lib/roda/plugins/heartbeat.rb

Instance Method Summary collapse

Instance Method Details

#callObject

If the request is for a heartbeat path, return the heartbeat response.



25
26
27
28
29
30
31
32
33
# File 'lib/roda/plugins/heartbeat.rb', line 25

def call
  if env[PATH_INFO] == opts[:heartbeat_path]
    response = HEARTBEAT_RESPONSE.dup
    response[1] = Hash[response[1]]
    response
  else
    super
  end
end