Reputation: 3882
I overload some classes of a module with an initializer script. In the module there is a class called Date
so it is not possible to use Date.today
or other date methods. How can i access Ruby/Rails core date class? Rails::Date
does not work.
Upvotes: 2
Views: 247
Reputation: 15492
You can just use "::" before the Date class.
Rails just extends the Ruby Core Date class, so you can just use
::Date.today
Upvotes: 3