From a550d77963365b288f0da1d3801d68a0e9765ca3 Mon Sep 17 00:00:00 2001 From: Guillaume Malette Date: Wed, 10 Aug 2016 09:50:36 -0400 Subject: [PATCH] Remove module_eval since is public since 2.1 --- lib/turbograft.rb | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/lib/turbograft.rb b/lib/turbograft.rb index 9f5f2493..23473d27 100644 --- a/lib/turbograft.rb +++ b/lib/turbograft.rb @@ -35,10 +35,8 @@ def referer end ActiveSupport.on_load(:action_view) do - (ActionView::RoutingUrlFor rescue ActionView::Helpers::UrlHelper).module_eval do - prepend XHRUrlFor - end - end unless RUBY_VERSION =~ /^1\.8/ + (ActionView::RoutingUrlFor rescue ActionView::Helpers::UrlHelper).prepend(XHRUrlFor) + end end end end