From 00bc73f625da10b6c4243755fcec9763c2e10ce4 Mon Sep 17 00:00:00 2001 From: Peter Argany Date: Tue, 28 Jul 2020 14:38:39 -0700 Subject: [PATCH] Fix misleading comment in RCTFabricSurface API Summary: Using RCTFabricSurface in bridgeless mode, this comment seems incorrect to me. `[_surface start]` needs to be called after initialization, or else the stage and `SurfacePresenter` registration never happen. Maybe this comment used to be true, but it is misleading with the current implementation. Changelog: [Internal] Reviewed By: shergin Differential Revision: D22800934 fbshipit-source-id: c396cbd3fc1749b8e7ab571c9e7bc05cd352fc14 --- React/Fabric/Surface/RCTFabricSurface.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/React/Fabric/Surface/RCTFabricSurface.h b/React/Fabric/Surface/RCTFabricSurface.h index 5895b02c20f..9e2e01117af 100644 --- a/React/Fabric/Surface/RCTFabricSurface.h +++ b/React/Fabric/Surface/RCTFabricSurface.h @@ -71,9 +71,7 @@ NS_ASSUME_NONNULL_BEGIN * A Surface object can be stopped and then restarted. * The starting process includes initializing all underlying React Native * infrastructure and running React app. - * Just initialized Surface object starts automatically, there is no need - * to call `start` explicitly. Surface also stops itself on deallocation - * automatically. + * Surface stops itself on deallocation automatically. * Returns YES in case of success. Returns NO if the Surface is already * started or stopped. */