Sha256: e346c80cdd51c9f39dfba83636eb451f8bf11385d5b913963c36944c9fa6464f

Contents?: true

Size: 494 Bytes

Versions: 1

Compression:

Stored size: 494 Bytes

Contents

module Gon
  module Request
    class << self

      def env
        @request_env if defined? @request_env
      end

      def env=(environment)
        @request_env = environment
        @request_env['gon'] ||= {}
      end

      def id
        @request_id if defined? @request_id
      end

      def id=(request_id)
        @request_id = request_id
      end

      def gon
        env['gon'] if env
      end

      def clear
        env && (env['gon'] = {})
      end

    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
gon-3.0.5 lib/gon/request.rb