88#import " RCTSurfaceTouchHandler.h"
99
1010#import < React/RCTIdentifierPool.h>
11+ #import < React/RCTLog.h>
1112#import < React/RCTUtils.h>
1213#import < React/RCTViewComponentView.h>
1314
@@ -206,8 +207,8 @@ - (void)_updateTouches:(NSSet<UITouch *> *)touches
206207{
207208 for (UITouch *touch in touches) {
208209 auto iterator = _activeTouches.find (touch);
209- RCTAssert (iterator != _activeTouches.end (), @" Inconsistency between local and UIKit touch registries" );
210210 if (iterator == _activeTouches.end ()) {
211+ RCTLogWarn (@" Inconsistency between local and UIKit touch registries" );
211212 continue ;
212213 }
213214
@@ -219,8 +220,8 @@ - (void)_unregisterTouches:(NSSet<UITouch *> *)touches
219220{
220221 for (UITouch *touch in touches) {
221222 auto iterator = _activeTouches.find (touch);
222- RCTAssert (iterator != _activeTouches.end (), @" Inconsistency between local and UIKit touch registries" );
223223 if (iterator == _activeTouches.end ()) {
224+ RCTLogWarn (@" Inconsistency between local and UIKit touch registries" );
224225 continue ;
225226 }
226227 auto &activeTouch = iterator->second ;
@@ -236,8 +237,8 @@ - (void)_unregisterTouches:(NSSet<UITouch *> *)touches
236237
237238 for (UITouch *touch in touches) {
238239 auto iterator = _activeTouches.find (touch);
239- RCTAssert (iterator != _activeTouches.end (), @" Inconsistency between local and UIKit touch registries" );
240240 if (iterator == _activeTouches.end ()) {
241+ RCTLogWarn (@" Inconsistency between local and UIKit touch registries" );
241242 continue ;
242243 }
243244 activeTouches.push_back (iterator->second );
0 commit comments