aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/sprockets/assets.rake
diff options
context:
space:
mode:
authorAlex Yakoubian <alex@simplevue.com>2011-09-08 13:44:08 -0700
committerAlex Yakoubian <alex@simplevue.com>2011-09-08 13:44:08 -0700
commit901c02d86a1e2cccc8cc2c6ea9ec3f68a6c72607 (patch)
treed7301400831610f1795f1a8d691851312437507f /actionpack/lib/sprockets/assets.rake
parente05d4cea69919ed0a2e5832bde120b5d0f12c0ec (diff)
downloadrails-901c02d86a1e2cccc8cc2c6ea9ec3f68a6c72607.tar.gz
rails-901c02d86a1e2cccc8cc2c6ea9ec3f68a6c72607.tar.bz2
rails-901c02d86a1e2cccc8cc2c6ea9ec3f68a6c72607.zip
Fixed assets precompile regex, now accepts Procs
Diffstat (limited to 'actionpack/lib/sprockets/assets.rake')
-rw-r--r--actionpack/lib/sprockets/assets.rake2
1 files changed, 2 insertions, 0 deletions
diff --git a/actionpack/lib/sprockets/assets.rake b/actionpack/lib/sprockets/assets.rake
index a8128d9a82..893ecf58fe 100644
--- a/actionpack/lib/sprockets/assets.rake
+++ b/actionpack/lib/sprockets/assets.rake
@@ -26,6 +26,8 @@ namespace :assets do
env.each_logical_path do |logical_path|
if path.is_a?(Regexp)
next unless path.match(logical_path)
+ elsif path.is_a?(Proc)
+ next unless path.call(logical_path)
else
next unless File.fnmatch(path.to_s, logical_path)
end