[TIMOB-3113] iOS: String.format does not return correct result for given value
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Low |
Status | Closed |
Resolution | Needs more info |
Resolution Date | 2017-06-14T17:26:44.000+0000 |
Affected Version/s | Release 3.0.0 |
Fix Version/s | n/a |
Components | iOS |
Labels | core |
Reporter | Jaime Fuhr |
Assignee | Ingo Muschenetz |
Created | 2011-04-15T03:37:17.000+0000 |
Updated | 2017-06-14T17:26:45.000+0000 |
Description
String.format does not return a proper string for this code:
var result = String.format('%05d', 2);
The result should be '00002' but instead it returns '00000'. Build version is 1.5.1.
Another developer encountered an error using String.format in build 1.5.2. See http://developer.appcelerator.com/question/111041/trying-to-use-stringformat-for-leading-zero"> http://developer.appcelerator.com/question/111041/trying-to-use-str...
Thanks!
Jaime
Confirmed SDK 2.2.0.014b86f Test code:
Closing ticket because the URL provided is no longer working so there's no way to find the test case.