From 0f682f01e7f29f004dbfada1c233d3524297fb81 Mon Sep 17 00:00:00 2001 From: Graham Bates Date: Thu, 6 Dec 2012 23:10:03 +0000 Subject: [PATCH] Fix scale in url replacement - issue #37. --- foresight.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/foresight.js b/foresight.js index 3ee4244..26ef910 100755 --- a/foresight.js +++ b/foresight.js @@ -756,6 +756,9 @@ newSrc = img[ DEFAULT_SRC ].replace( findValue, img[ APPLIED_IMAGE_SET_ITEM ][ URI_REPLACE ] ), formatReplace = [ REQUEST_WIDTH, REQUEST_HEIGHT, SCALE, SCALE_ROUNDED ]; + img[ SCALE ] = img[ APPLIED_IMAGE_SET_ITEM ][ SCALE ]; + img[ SCALE_ROUNDED ] = img[ APPLIED_IMAGE_SET_ITEM ][ SCALE_ROUNDED ]; + // loop through all the possible format keys and // replace them with their respective value for this image for ( f = 0; f < formatReplace.length; f++ ) {