./lib/vendor/lux/assets_helper.rb in lux_assets-0.2.9 vs ./lib/vendor/lux/assets_helper.rb in lux_assets-0.2.11
- old
+ new
@@ -22,15 +22,15 @@
# asset('js/main')
# will render 'app/assets/js/main/index.coffee' as http://aset.path/assets/main-index-md5hash.js
def asset file, opts={}
opts = { dev_file: opts } unless opts.class == Hash
+ # return internet links
+ return asset_include file if file.starts_with?('/') || file.starts_with?('http')
+
if Lux.config(:compile_assets)
# return second link if it is defined and we are in dev mode
return asset_include opts[:dev_file] if opts[:dev_file]
-
- # return internet links
- return asset_include file if file.starts_with?('/') || file.starts_with?('http')
# try to create list of incuded files and show every one of them
files = LuxAssets.files(file) || []
data = files.inject([]) do |total, asset|
if asset.is_a?(Proc)
\ No newline at end of file