Sha256: 1accc4dce6c720bd8e109e5a43a3eddbfee48a220d62018c4bae4c31c00f7997

Contents?: true

Size: 581 Bytes

Versions: 3

Compression:

Stored size: 581 Bytes

Contents

# encoding: UTF-8
#
# Copyright (c) 2010-2015 GoodData Corporation. All rights reserved.
# This source code is licensed under the BSD-style license found in the
# LICENSE file in the root directory of this source tree.

require 'logger'

require_relative 'base_middleware'

module GoodData
  module Bricks
    class ParamsInspectMiddleware < Bricks::Middleware
      def call(params)
        inspect = params[:inspect_params] || params['inspect_params']
        puts 'Inspecting Parameters ...'
        puts JSON.pretty_generate(params) if inspect.to_b
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
gooddata-bricks-0.8.0 lib/gooddata/bricks/middleware/params_inspect_middleware.rb
gooddata-bricks-0.7.0 lib/gooddata/bricks/middleware/params_inspect_middleware.rb
gooddata-bricks-0.6.0 lib/gooddata/bricks/middleware/params_inspect_middleware.rb