From e64a8ba76d3e9816729000cde57ec067f0748537 Mon Sep 17 00:00:00 2001 From: ColCh Date: Tue, 4 Feb 2014 00:33:47 +0400 Subject: [PATCH] =?UTF-8?q?=D0=9F=D0=BE=D0=BB=D1=83=D1=87=D1=88=D0=B5=20?= =?UTF-8?q?=D1=80=D0=B5=D0=B0=D0=BB=D0=B8=D0=B7=D0=B0=D1=86=D0=B8=D1=8F=20?= =?UTF-8?q?PropertyDescriptor.toStringValue?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/abstractions.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/abstractions.js b/src/abstractions.js index 34714b5..8079915 100644 --- a/src/abstractions.js +++ b/src/abstractions.js @@ -300,11 +300,11 @@ */ PropertyDescriptor.prototype.toStringValue = function (elem, numericValue) { - if (numericValue.length === 0) { + if (numericValue.length === 1) { + return numericValue[0] + ( this.propName in toStringValueNoPX ? '' : 'px' ); + } else if (numericValue.length === 0) { return ''; - } else { - return numericValue + ( this.propName in toStringValueNoPX ? '' : 'px' ); - } + } // else ? };