Sha256: 699c7c0196c599d2a167772b7b4b1eba9d2c86e44db40b0154160bd43c61127f
Contents?: true
Size: 474 Bytes
Versions: 12
Compression:
Stored size: 474 Bytes
Contents
module Coprl::Presenters::WebClient::Helpers::Sinatra module LocalVariables # A sinatra specific helper to see if a local variable is defined # This passes the binding from the evaluating (erb) context # We don't do this inline, because rails and sintra have different variable names for the same thing def bound_locals_include?(variable, __binding__) locals = __binding__.local_variable_get(:locals) locals.include? variable end end end
Version data entries
12 entries across 12 versions & 1 rubygems