Sha256: e4144f00af24dd34d8ddac577e496917d8d0c47020ecc6117ea005785210d55a
Contents?: true
Size: 475 Bytes
Versions: 6
Compression:
Stored size: 475 Bytes
Contents
class Lux::Response::Header attr_reader :data def initialize @data = {} end def [] key @data[key.downcase] end def []= key, value @data[key.downcase] = value end def merge hash for key, value in hash @data[key.downcase] = value end @data end def delete name @data.delete name.downcase end def to_h # data['Set-Cookie'] = data.delete('set-cookie') if data['set-cookie'] @data#.to_h.sort.to_h end end
Version data entries
6 entries across 6 versions & 1 rubygems