Sha256: 10f2160f4b59be24250e14b1b8b0436a1d7e357fba86daec2b70d8ff06e9e033
Contents?: true
Size: 665 Bytes
Versions: 1
Compression:
Stored size: 665 Bytes
Contents
class Card module Env # These methods are all handled in serialization and are thus preserved for the # integrate_with_delay phase module Serializable def ip request&.remote_ip end def protocol request&.protocol end def host request&.host end def origin Cardio.config.deck_origin || "#{protocol}#{request&.host_with_port}" end def ajax request&.xhr? || params[:simulate_xhr] end alias_method :ajax?, :ajax def html !controller || params[:format].in?([nil, "html"]) end alias_method :html?, :html end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
card-1.104.2 | lib/card/env/serializable.rb |