Skip to content

Commit

Permalink
Let all plugins not just engines have a config/routes.rb file
Browse files Browse the repository at this point in the history
  • Loading branch information
dhh committed Nov 26, 2008
1 parent 7d8f9ef commit 3cc9d1c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion railties/lib/rails/plugin/loader.rb
Original file line number Diff line number Diff line change
Expand Up @@ -68,8 +68,9 @@ def controller_paths
engines.collect(&:controller_path)
end

# Returns an array of routing.rb files from all the plugins that include config/routes.rb
def routing_files
engines.select(&:routed?).collect(&:routing_file)
plugins.select(&:routed?).collect(&:routing_file)
end


Expand Down

2 comments on commit 3cc9d1c

@lazyatom
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the light of this commit, I’m not sure if we need the #engine? method in Plugin, or the #engines method in Plugin::Loader?

@dhh
Copy link
Member Author

@dhh dhh commented on 3cc9d1c Nov 27, 2008

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The call to controller_paths uses it.

Please sign in to comment.