summaryrefslogtreecommitdiffhomepage
path: root/modules/luci-base/htdocs/luci-static
diff options
context:
space:
mode:
Diffstat (limited to 'modules/luci-base/htdocs/luci-static')
-rw-r--r--modules/luci-base/htdocs/luci-static/resources/cbi.js10
1 files changed, 5 insertions, 5 deletions
diff --git a/modules/luci-base/htdocs/luci-static/resources/cbi.js b/modules/luci-base/htdocs/luci-static/resources/cbi.js
index 701de0386b..d4d61eb381 100644
--- a/modules/luci-base/htdocs/luci-static/resources/cbi.js
+++ b/modules/luci-base/htdocs/luci-static/resources/cbi.js
@@ -566,7 +566,7 @@ String.prototype.format = function()
switch(pType) {
case 'b':
- subst = (+param || 0).toString(2);
+ subst = (~~param || 0).toString(2);
break;
case 'c':
@@ -574,7 +574,7 @@ String.prototype.format = function()
break;
case 'd':
- subst = ~~(+param || 0);
+ subst = (~~param || 0);
break;
case 'u':
@@ -588,7 +588,7 @@ String.prototype.format = function()
break;
case 'o':
- subst = (+param || 0).toString(8);
+ subst = (~~param || 0).toString(8);
break;
case 's':
@@ -596,11 +596,11 @@ String.prototype.format = function()
break;
case 'x':
- subst = ('' + (+param || 0).toString(16)).toLowerCase();
+ subst = ('' + (~~param || 0).toString(16)).toLowerCase();
break;
case 'X':
- subst = ('' + (+param || 0).toString(16)).toUpperCase();
+ subst = ('' + (~~param || 0).toString(16)).toUpperCase();
break;
case 'h':