Welcome to mirror list, hosted at ThFree Co, Russian Federation.

routing_draw.rb « initializers « config - gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 25003cf0239045f497a9153b8a7c286ecce18a2f (plain)
1
2
3
4
5
6
7
# Adds draw method into Rails routing
# It allows us to keep routing splitted into files
class ActionDispatch::Routing::Mapper
  def draw(routes_name)
    instance_eval(File.read(Rails.root.join("config/routes/#{routes_name}.rb")))
  end
end