diff options
author | Yehuda Katz + Carl Lerche <ykatz+clerche@engineyard.com> | 2009-11-06 17:21:39 -0800 |
---|---|---|
committer | Yehuda Katz + Carl Lerche <ykatz+clerche@engineyard.com> | 2009-11-11 18:09:16 -0800 |
commit | 82b9b151ffde44305d67744c0bfd9bb5505f6fbe (patch) | |
tree | a30f92f7d438e2fede751509d4772957cdefeda9 /railties/lib/rails/paths.rb | |
parent | fca32eb6c5b41e4f19a25b7b246c4a8a3d763667 (diff) | |
download | rails-82b9b151ffde44305d67744c0bfd9bb5505f6fbe.tar.gz rails-82b9b151ffde44305d67744c0bfd9bb5505f6fbe.tar.bz2 rails-82b9b151ffde44305d67744c0bfd9bb5505f6fbe.zip |
Refactor plugins
Diffstat (limited to 'railties/lib/rails/paths.rb')
-rw-r--r-- | railties/lib/rails/paths.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/railties/lib/rails/paths.rb b/railties/lib/rails/paths.rb index 0f24106353..b3d105d8c7 100644 --- a/railties/lib/rails/paths.rb +++ b/railties/lib/rails/paths.rb @@ -64,7 +64,7 @@ module Rails end class Path - include PathParent + include PathParent, Enumerable attr_reader :path attr_accessor :glob @@ -83,6 +83,10 @@ module Rails @root.all_paths << self end + def each + to_a.each { |p| yield p } + end + def push(path) @paths.push path end |