[TIMOB-8913] MobileWeb: Ti.App.Properties getters return null for falsey default values
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | High |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2012-05-18T10:48:00.000+0000 |
Affected Version/s | Release 2.0.1 |
Fix Version/s | Release 2.1.0, Sprint 2012-10 MW |
Components | MobileWeb |
Labels | n/a |
Reporter | Chris Barber |
Assignee | Chris Barber |
Created | 2012-04-29T07:36:32.000+0000 |
Updated | 2017-03-21T18:56:40.000+0000 |
Description
There's a bug in Ti.App.Properties where falsey default values return null (if the property value is undefined.
The problem is in the getProp() function where the correct line should be:
return value === void 0 ? lang.val(defaultValue, null) : types[type] ? types[type](value) : value;
Attachments
File | Date | Size |
---|---|---|
app.js | 2012-05-18T03:30:41.000+0000 | 148 |
This might be related to a request I submitted. As I have not looked into the API source code, I'm not certain. But it seem it be the same problem. See
Pull request: https://github.com/appcelerator/titanium_mobile/pull/2221
Closing ticket as fixed.