该应用程序在iOS 11更新之前正常工作.在iOS 11推出之后,一些用户得到了以下崩溃但我无法在模拟器iOS 11中重现这一点.基于fabric.io,并非所有iOS 11都经历过这种情况,到目前为止我只收到了来自4个用户的22个崩溃报告.需要一些帮助,谢谢.
Fatal Exception: NSRangeException
*** -[__NSArrayM objectAtIndex:]: index 9223372036854775807 beyond bounds [0 .. 1]
Fatal Exception: NSRangeException
0 CoreFoundation 0x185b7fd38 __exceptionPreprocess
1 libobjc.A.dylib 0x185094528 objc_exception_throw
2 CoreFoundation 0x185b18c44 _CFArgv
3 CoreFoundation 0x185a48cc0 -[__NSArrayM removeObjectAtIndex:]
4 UIKit 0x18f1e4aa8 -[UIPickerView selectedRowInComponent:]
5 UIKit 0x18fa4a224 -[_UIDatePickerMode_Date _dateForYearRow:]
6 UIKit 0x18fa46dd8 -[_UIDatePickerMode dateForRow:inCalendarUnit:]
7 UIKit 0x18fa47a70 -[_UIDatePickerMode _updateSelectedDateComponentsWithNewValueInComponent:usingSelectionBarValue:]
8 UIKit 0x18fa47d18 -[_UIDatePickerMode selectedDateComponents]
9 UIKit 0x18fa3b370 -[_UIDatePickerView _updatedLastSelectedComponentsByValidatingSelectedDateWithLastManipulatedComponent:]
10 UIKit 0x18fa3a7e8 -[_UIDatePickerView _setDate:animated:forced:]
11 UIKit 0x18fa3ad24 -[_UIDatePickerView _setMode:]
12 UIKit …Run Code Online (Sandbox Code Playgroud) 我最近刚从android迁移到React Native。因此需要一些帮助。为什么我无法访问同一类上的变量,例如,当我从另一个类调用URL_API_SERVER时,却给了我“ Undefined / api / v2”。
class Constant {
static BASE_URL = 'https://xxxxx';
static URL_API_SERVER = this.BASE_URL + '/api/v2';
static STATIC_BASEURL = this.BASE_URL + '/static';
static URLSTRING_FAQ = this.STATIC_BASEURL + '/FAQ.html';
static URLSTRING_TOU = this.STATIC_BASEURL + '/TOU.html';
}
export default Constant;
Run Code Online (Sandbox Code Playgroud)