Created
November 17, 2010 01:17
-
-
Save eduardordm/702837 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Trace is a model in vendor/plugins/mylogger/lib/app/models/trace.rb | |
# vendor/plugins/mylogger/lib/mylogger.rb | |
#... | |
module MyLoggerImpl | |
def self.trace(controller_instance) | |
puts 'Tracing' | |
controller_instance.instance_eval do | |
t = Trace.new | |
t.path = request.url | |
t.save | |
end | |
end | |
# ... | |
end | |
# Error is: uninitialized constant MyLogger::MyLoggerImpl::Trace | |
# Trace is obviously not in that module. But, how can I use it in my plugin? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment