align userinfo access in js thread
This commit is contained in:
parent
4376e37836
commit
4ef508d3a7
@ -223,11 +223,12 @@ - (void)destroyContext:(NSString *)contextId {
|
|||||||
}
|
}
|
||||||
|
|
||||||
- (void)callbackTimer:(NSTimer *)timer {
|
- (void)callbackTimer:(NSTimer *)timer {
|
||||||
NSDictionary *userInfo = timer.userInfo;
|
|
||||||
NSNumber *timerId = [userInfo valueForKey:@"timerId"];
|
|
||||||
NSNumber *repeat = [userInfo valueForKey:@"repeat"];
|
|
||||||
__weak typeof(self) _self = self;
|
__weak typeof(self) _self = self;
|
||||||
dispatch_async(self.jsQueue, ^() {
|
dispatch_async(self.jsQueue, ^() {
|
||||||
|
NSDictionary *userInfo = timer.userInfo;
|
||||||
|
NSNumber *timerId = [userInfo valueForKey:@"timerId"];
|
||||||
|
NSNumber *repeat = [userInfo valueForKey:@"repeat"];
|
||||||
|
|
||||||
__strong typeof(_self) self = _self;
|
__strong typeof(_self) self = _self;
|
||||||
@try {
|
@try {
|
||||||
[self invokeDoricMethod:DORIC_TIMER_CALLBACK, timerId, nil];
|
[self invokeDoricMethod:DORIC_TIMER_CALLBACK, timerId, nil];
|
||||||
|
Reference in New Issue
Block a user