Skip to content

Instantly share code, notes, and snippets.

@grobie
Created October 9, 2008 14:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save grobie/15785 to your computer and use it in GitHub Desktop.
Save grobie/15785 to your computer and use it in GitHub Desktop.
module ActiveSupport
module Dependencies
def load_missing_constant_with_shared_code(from_mod, const_name)
puts "Looking for #{const_name}"
load_missing_constant_without_shared_code(from_mod, const_name)
end
alias_method_chain :load_missing_constant, :shared_code
end
end
# => NameError: undefined method `load_missing_constant' for module `ActiveSupport::Dependencies'
# line 484, rails 2.1.1, activesupport/dependencies.rb
ActiveSupport::Dependencies.load_missing_constant self, const_name
# ????
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment