Skip to content
This repository was archived by the owner on Feb 2, 2023. It is now read-only.

Commit 3512cf4

Browse files
committed
assert we are on the main thread before accessing view.
1 parent ec4b666 commit 3512cf4

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

AsyncDisplayKit/ASViewController.mm

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -195,6 +195,7 @@ - (ASEnvironmentTraitCollection)environmentTraitCollectionForUITraitCollection:(
195195
return [asyncTraitCollection environmentTraitCollection];
196196
}
197197

198+
ASDisplayNodeAssertMainThread();
198199
ASEnvironmentTraitCollection asyncTraitCollection = ASEnvironmentTraitCollectionFromUITraitCollection(traitCollection);
199200
asyncTraitCollection.containerWindowSize = self.view.frame.size;
200201
return asyncTraitCollection;

0 commit comments

Comments
 (0)