Steps to Reproduce
Ti.App.Properties.setObject('objectName', undefined);
Ti.App.Properties.getObject('objectName');
I submit it as an error because it is possible that may try to save object which is not defined and user may be not aware about that (espesially if he downloaded data via http)
var object = getObjectViaHttp();
Ti.App.Properties.setObject('objectName', object.propertyNotExist);
Ti.App.Properties.getObject('objectName');
Actual Result
[ERROR]: SyntaxError: Unexpected token u
[ERROR]: File: app.js
[ERROR]: Line: undefined
[ERROR]: SourceId: undefined
[ERROR]: Backtrace:
[ERROR]: undefined
Expected Result
1. setObject should accept 'undefined' as 'null'
2. getObject should have some behaviour predefined if readed object is wrong,
3. Error message should be better, because such error is almost impossible to track
From my opinion, this is not a valid issue. Developers should validate I/O before trying to persist it.
I dissagree. If the type of passed value is wrong/unsupported then Appcelerator should throw errow at setObject. In my opinion it is a bug because behaviour at one method (setObject) cause (not clear) error at different one (getObject). And this error is native so before every getObject you would have to do try/catch (which would not be good programming practice) and if app throws error then clear object stored in memory.