Comparing version 3.1.0 to 3.1.1
@@ -0,1 +1,5 @@ | ||
## 3.1.1 (April 25, 2017) | ||
- Fixed crash on a number processing when it used not in a list (#335) | ||
## 3.1.0 (April 24, 2017) | ||
@@ -2,0 +6,0 @@ |
@@ -26,3 +26,3 @@ var packNumber = require('./Number.js').pack; | ||
module.exports = function compressDimension(node, item) { | ||
var value = packNumber(node.value, item ? item.prev : null); | ||
var value = packNumber(node.value, item); | ||
@@ -29,0 +29,0 @@ node.value = value; |
@@ -12,7 +12,7 @@ var OMIT_PLUSSIGN = /^(?:\+|(-))?0*(\d*)(?:\.0*|(\.\d*?)0*)?$/; | ||
function packNumber(value, prev) { | ||
function packNumber(value, item) { | ||
// omit plus sign only if no prev or prev is safe type | ||
var regexp = prev === null || !unsafeToRemovePlusSignAfter.hasOwnProperty(prev.data.type) | ||
? OMIT_PLUSSIGN | ||
: KEEP_PLUSSIGN; | ||
var regexp = item && item.prev !== null && unsafeToRemovePlusSignAfter.hasOwnProperty(item.prev.data.type) | ||
? KEEP_PLUSSIGN | ||
: OMIT_PLUSSIGN; | ||
@@ -38,4 +38,4 @@ // 100 -> '100' | ||
module.exports = function(node, item) { | ||
node.value = packNumber(node.value, item.prev); | ||
node.value = packNumber(node.value, item); | ||
}; | ||
module.exports.pack = packNumber; |
{ | ||
"name": "csso", | ||
"version": "3.1.0", | ||
"version": "3.1.1", | ||
"description": "CSSO (CSS Optimizer) is a CSS minifier with structural optimisations", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
311290