change destroy order

This commit is contained in:
王劲鹏 2020-04-22 13:55:07 +08:00 committed by osborn
parent a1c0e8e30c
commit d32f714050
2 changed files with 2 additions and 2 deletions

View File

@ -60,8 +60,9 @@ - (DoricViewNode *)targetViewNode:(NSString *)viewId {
}
- (void)dealloc {
[self callEntity:DORIC_ENTITY_DESTROY withArgumentsArray:@[]];
[[DoricContextManager instance] destroyContext:self];
[self callEntity:DORIC_ENTITY_DESTROY withArgumentsArray:@[]];
[self.driver destroyContext:self.contextId];
}
- (DoricAsyncResult *)callEntity:(NSString *)method, ... {

View File

@ -72,7 +72,6 @@ - (void)destroyContext:(DoricContext *)context {
dispatch_sync(self.mapQueue, ^() {
[self.doricContextMap removeObjectForKey:contextId];
});
[context.driver destroyContext:contextId];
}
- (NSArray *)aliveContexts {