Sha256: a6462b4bde999e45a35ba501d2aff088a84620fa2df7494cf62fbebd82b29c25

Contents?: true

Size: 384 Bytes

Versions: 1

Compression:

Stored size: 384 Bytes

Contents

module Sandboxy
    class Middleware

        def initialize app
            @app = app
        end

        def call env
            previous_sandbox = $sandbox
            $sandbox = Sandboxy.environment == 'sandbox' ? true : false
            puts 'Sandbox: Moved to ' + Sandboxy.environment + ' environment' if $sandbox != previous_sandbox
        end

    end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
sandboxy-1.1.0 lib/sandboxy/middleware.rb