how to add a method without coding it directly into app?
ronald.evangelista
ironald at gmail.com
Thu Jun 5 04:19:45 EDT 2008
i'm missing something here.
how would I code this outside the application to be shared with other
Camping apps?
module Blog::Controllers
module AuthenticationHelper
def self.included(base)
class << base
define_method :authenticate do |*a|
a.each do |meth|
if method_defined?(meth.to_s)
alias_method "__#{meth}__", meth
class_def(meth) do |*a|
@state.Back=@env.REQUEST_URI
return redirect(Login) if @state.blank?
or @state.user_id.nil?
send("__#{meth}__", *a)
end
end
end
end
end
end
end
end
any hints? thanks!
More information about the Camping-list
mailing list