[TIMOB-5008] iOS: Ti.App.iOS.scheduleLocalNotification crashes without userInfo
| GitHub Issue | n/a |
|---|---|
| Type | Bug |
| Priority | High |
| Status | Closed |
| Resolution | Fixed |
| Resolution Date | 2011-11-05T15:40:41.000+0000 |
| Affected Version/s | Release 1.7.2 |
| Fix Version/s | Sprint 2011-35, Release 1.8.0 |
| Components | iOS |
| Labels | n/a |
| Reporter | Matthew Congrove |
| Assignee | Reggie Seagraves |
| Created | 2011-08-15T10:37:54.000+0000 |
| Updated | 2014-06-19T12:46:29.000+0000 |
Description
Creating a LocalNotification without the userInfo property causes the application to crash. This breaks:
Ti.App.iOS.scheduleLocalNotification({
date: new Date(new Date().getTime() + 3000),
alertBody: "Let's crash!"
});
Ti.App.iOS.addEventListener('notification', function(e) {});
Adding dummy data will work (and is an acceptable work-around for the time being):
Ti.App.iOS.scheduleLocalNotification({
date: new Date(new Date().getTime() + 3000),
userInfo: {why: 'me'},
alertBody: "I'm fine"
});
Ti.App.iOS.addEventListener('notification', function(e) {});
Attachments
| File | Date | Size |
|---|---|---|
| app.js | 2011-08-31T15:36:46.000+0000 | 1343 |
| bg.js | 2011-08-31T15:39:24.000+0000 | 987 |
Tested with 1.8.0.v20110906155354 with on iPhone 4 4.3.4 iPad2 4.3.5 Simulator 4.0
Standardizing summary and labels.