{ "id": "151377", "key": "TIMOB-19566", "fields": { "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false }, "project": { "id": "10153", "key": "TIMOB", "name": "Titanium SDK/CLI", "projectCategory": { "id": "10100", "description": "Titanium and related SDKs used in application development", "name": "Client" } }, "fixVersions": [ { "id": "16997", "name": "Release 5.2.0", "archived": false, "released": true, "releaseDate": "2016-02-23" } ], "resolution": { "id": "1", "description": "A fix for this issue is checked into the tree and tested.", "name": "Fixed" }, "resolutiondate": "2015-10-05T21:22:51.000+0000", "created": "2015-09-22T13:31:10.000+0000", "priority": { "name": "High", "id": "2" }, "labels": [ "locale" ], "versions": [ { "id": "16925", "description": "WatchKit Support--all going into 5.0 now", "name": "Release 5.0.0", "archived": true, "released": true, "releaseDate": "2015-09-16" } ], "issuelinks": [ { "id": "49686", "type": { "id": "10002", "name": "Duplicate", "inward": "is duplicated by", "outward": "duplicates" }, "inwardIssue": { "id": "151984", "key": "TIMOB-19860", "fields": { "summary": "Titanium local differ between simulator to device", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "priority": { "name": "Critical", "id": "1" }, "issuetype": { "id": "1", "description": "A problem which impairs or prevents the functions of the product.", "name": "Bug", "subtask": false } } } }, { "id": "49693", "type": { "id": "10002", "name": "Duplicate", "inward": "is duplicated by", "outward": "duplicates" }, "inwardIssue": { "id": "151458", "key": "AC-380", "fields": { "summary": "iOS9: Ti.Locale.currentLanguage() returns a combination of ISO 2-letter language and country codes", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "issuetype": { "id": "7", "description": "gh.issue.story.desc", "name": "Story", "subtask": false } } } } ], "assignee": { "name": "apetkov", "key": "apetkov", "displayName": "Angel Petkov", "active": true, "timeZone": "America/Los_Angeles" }, "updated": "2016-01-22T00:51:36.000+0000", "status": { "description": "The issue is considered finished, the resolution is correct. Issues which are closed can be reopened.", "name": "Closed", "id": "6", "statusCategory": { "id": 3, "key": "done", "colorName": "green", "name": "Done" } }, "components": [ { "id": "10206", "name": "iOS", "description": "iOS Platform" } ], "description": "Since iOS 9 the same Titanium SDK returns a different value for {{Ti.Locale.currentLanguage}}. It now returns the full locale instead of just the language:\r\n\r\n*app.js*\r\n{code}\r\nconsole.log('currentLanguage ' + Ti.Locale.currentLanguage);\r\nconsole.log('currentCountry ' + Ti.Locale.currentCountry);\r\nconsole.log('currentLocale ' + Ti.Locale.currentLocale);\r\n{code}\r\n\r\n*iOS 8.4*\r\n{code}\r\n[INFO] currentLanguage en\r\n[INFO] currentCountry US\r\n[INFO] currentLocale en-US\r\n{code}\r\n\r\n*iOS 9*\r\n{code}\r\n[INFO] currentLanguage en-US\r\n[INFO] currentCountry US\r\n[INFO] currentLocale en-US\r\n{code}\r\n\r\n*Code*\r\n* https://github.com/appcelerator/titanium_mobile/blob/master/iphone/Classes/LocaleModule.m#L26-L29\r\n* https://github.com/appcelerator/titanium_mobile/blob/master/iphone/Classes/TiLocale.m#L32-L42\r\n\r\nFound by Q&A user\r\nhttps://community.appcelerator.com/topic/3430/ti-locale-getcurrentlanguage-on-ios-9-returns-en-us-instead-en", "attachment": [], "flagged": false, "summary": "Ti.Locale.currentLanguage returns locale on iOS 9", "creator": { "name": "fokkezb", "key": "fokke", "displayName": "Fokke Zandbergen", "active": true, "timeZone": "Europe/Amsterdam" }, "subtasks": [], "reporter": { "name": "fokkezb", "key": "fokke", "displayName": "Fokke Zandbergen", "active": true, "timeZone": "Europe/Amsterdam" }, "environment": "SDK 5.0.0.GA\r\niOS 8.4\r\niOS 9.0", "closedSprints": [ { "id": 494, "state": "closed", "name": "2015 Sprint 20 SDK", "startDate": "2015-09-26T00:29:19.845Z", "endDate": "2015-10-10T00:29:00.000Z", "completeDate": "2015-10-12T05:33:30.964Z", "originBoardId": 114 } ], "comment": { "comments": [ { "id": "365300", "author": { "name": "apetkov", "key": "apetkov", "displayName": "Angel Petkov", "active": true, "timeZone": "America/Los_Angeles" }, "body": "Thanks you for including so much detail in your ticket , should display the language without the location now. \r\n\r\n*PR* https://github.com/appcelerator/titanium_mobile/pull/7254", "updateAuthor": { "name": "apetkov", "key": "apetkov", "displayName": "Angel Petkov", "active": true, "timeZone": "America/Los_Angeles" }, "created": "2015-09-29T20:24:29.000+0000", "updated": "2015-09-30T18:14:14.000+0000" }, { "id": "366226", "author": { "name": "fokkezb", "key": "fokke", "displayName": "Fokke Zandbergen", "active": true, "timeZone": "Europe/Amsterdam" }, "body": "[~apetkov] this issue should be high pro because apps break on iOS9 without the fix. If we do a 5.0.3 this should be in it and for sure it must be in 5.1.0.", "updateAuthor": { "name": "fokkezb", "key": "fokke", "displayName": "Fokke Zandbergen", "active": true, "timeZone": "Europe/Amsterdam" }, "created": "2015-10-08T08:46:06.000+0000", "updated": "2015-10-08T08:46:06.000+0000" }, { "id": "375132", "author": { "name": "htbryant", "key": "htbryant", "displayName": "Harry Bryant", "active": true, "timeZone": "Europe/London" }, "body": "Verified as fixed as of 5.1.1.GA onwards. compared values of {{Ti.Locale.currentLanguage}} for iOS 9.2 & 8.4.\r\n\r\nTested on: \r\niPhone 6s Plus Device (9.2) & iPhone 6 Plus Device (8.4) \r\n\r\nMac OSX El Capitan 10.11 (15A284)\r\nTi SDK: 5.2.0.v20160114021251 & 5.1.1.GA\r\nAppc NPM: 4.2.3-1\r\nApp CLI: 5.2.0-231\r\nXcode 7.2\r\nNode v4.2.3 \r\n\r\n*Closing Ticket.*", "updateAuthor": { "name": "htbryant", "key": "htbryant", "displayName": "Harry Bryant", "active": true, "timeZone": "Europe/London" }, "created": "2016-01-22T00:51:31.000+0000", "updated": "2016-01-22T00:51:31.000+0000" } ], "maxResults": 6, "total": 6, "startAt": 0 } } }