Permalink
Browse files

Autoload YMaps ActionView helpers if ActionView defined

  • Loading branch information...
1 parent 93fdf69 commit 635bc3435a63d501268d0c5ea0a14345a6d7d366 Alexander Semyonov committed May 19, 2010
Showing with 4 additions and 0 deletions.
  1. +4 −0 lib/ymaps.rb
View
4 lib/ymaps.rb
@@ -9,3 +9,7 @@ def self.geocode(query)
Geokit::Geocoders::Yandex.geocode(query)
end
end
+
+if defined? ActionView
+ ActionView::Base.send(:include, YMaps::ActionView::Helpers)
+end

0 comments on commit 635bc34

Please sign in to comment.