Sha256: 6628627b47b68b2432cb414ea72f5d3a1c2013aff1d04966aa08de78cbd4f505
Contents?: true
Size: 471 Bytes
Versions: 1
Compression:
Stored size: 471 Bytes
Contents
require "params_encoding/version" require "base64" require "jwt" module ParamsEncoding class Error < StandardError; end def self.encode(options) raise 'Type error, currently only hash supported!' unless options.is_a?(Hash) token = ::JWT.encode options, nil, 'none' token end def self.decode(options) raise 'Type error, currently only hash supported!' unless options.is_a?(Hash) token = ::JWT.decode options, nil, false token end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
params_encoding-0.1.1 | lib/params_encoding.rb |