summaryrefslogtreecommitdiff
path: root/framework/Web/Javascripts/extended/string.js
diff options
context:
space:
mode:
Diffstat (limited to 'framework/Web/Javascripts/extended/string.js')
-rw-r--r--framework/Web/Javascripts/extended/string.js5
1 files changed, 1 insertions, 4 deletions
diff --git a/framework/Web/Javascripts/extended/string.js b/framework/Web/Javascripts/extended/string.js
index 9b4c501b..e265edf4 100644
--- a/framework/Web/Javascripts/extended/string.js
+++ b/framework/Web/Javascripts/extended/string.js
@@ -16,10 +16,7 @@ Object.extend(String.prototype, {
},
zerofill : function(len) {
- var s = this;
- var ix = /^[+-]/.test(s) ? 1 : 0;
- while (s.length<len) s = s.insert(ix, '0');
- return s;
+ return this.padLeft(len,'0');
},
trim : function() {