Sha256: 2217fa5ba2242e2bd98a13efd1de7c2aaffcc4f617b29d989070f71fe0e067b5
Contents?: true
Size: 367 Bytes
Versions: 38
Compression:
Stored size: 367 Bytes
Contents
module NoNotifierNeeded module UrlHelper def url_for(destination) unless destination.is_a?(Hash) || destination.match(/_path/i) raise ArgumentError.new(" must pass something that ends with a _path. #{destination} sent.") end to_send = "Rails.application.routes.url_helpers.#{destination}" instance_eval to_send end end end
Version data entries
38 entries across 38 versions & 1 rubygems