Browse files

asset_cache_buster arguments should match documentation

The documentation indicates that the second argument passed
to an asset_cache_buster method will be a string, but a File
is passed instead.

This poses the following problems:
1. A fatal error occurs if the file does not exist
2. The file descriptor is left open if the file exists

This commit addresses the issue by passing the real_path to
the provided asset_cache_buster method instead of a File instance
  • Loading branch information...
Jonathan Stewmon
Jonathan Stewmon committed Mar 9, 2013
1 parent c6d966f commit 59893af3f40138a89dbae04c6b91441eacadd4c5
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/compass/sass_extensions/functions/urls.rb
@@ -247,7 +247,7 @@ def compute_cache_buster(path, real_path)
if Compass.configuration.asset_cache_buster
args = [path]
if Compass.configuration.asset_cache_buster.arity > 1
- args << ( if real_path)
+ args << real_path
elsif real_path

0 comments on commit 59893af

Please sign in to comment.