lib/octopress-ink/plugin.rb in octopress-ink-1.0.0.rc.32 vs lib/octopress-ink/plugin.rb in octopress-ink-1.0.0.rc.33
- old
+ new
@@ -352,14 +352,12 @@
@files = add_new_assets(@files_dir, Assets::FileAsset)
end
def add_javascripts
find_assets(@javascripts_dir).each do |asset|
- if asset =~ /\.min\.js$/
- @no_compress_js << Assets::Javascript.new(self, @javascripts_dir, asset)
- elsif asset =~ /\.js$/
+ if asset.end_with?('js')
@js << Assets::Javascript.new(self, @javascripts_dir, asset)
- elsif File.extname(asset) =~ /\.coffee$/
+ elsif asset.end_with?('coffee')
@coffee << Assets::Coffeescript.new(self, @javascripts_dir, asset)
end
end
end