Sha256: e2b678775ddcbc145cc1cf2fc5fa1a4dbd444a5e359cc6ff07dc58ae4c1eb126
Contents?: true
Size: 382 Bytes
Versions: 119
Compression:
Stored size: 382 Bytes
Contents
require 'msgpack' require 'action_dispatch' module Acfs module Middleware # A middleware to encode request data with Message Pack. # class MessagePackEncoder < Base def call(request) request.body = ::MessagePack.dump(request.data) request.headers['Content-Type'] = 'application/x-msgpack' app.call request end end end end
Version data entries
119 entries across 119 versions & 1 rubygems