From 862bd2fa2aca900dff38c4185b3da0df1b11f125 Mon Sep 17 00:00:00 2001 From: Valentin Shergin Date: Thu, 5 Sep 2019 08:04:16 -0700 Subject: [PATCH] Fabric: Fixing small nit in `ParagraphComponentDescriptor` Summary: Trivial. `measureCache_` is unique pointer here. It cannot be `nullptr`. Reviewed By: JoshuaGross Differential Revision: D17200950 fbshipit-source-id: dc267eb6545a10322cc2f02690f90c6a50366f0e --- .../components/text/paragraph/ParagraphComponentDescriptor.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/ReactCommon/fabric/components/text/paragraph/ParagraphComponentDescriptor.h b/ReactCommon/fabric/components/text/paragraph/ParagraphComponentDescriptor.h index 80510ce44d6..b42ae6d93f1 100644 --- a/ReactCommon/fabric/components/text/paragraph/ParagraphComponentDescriptor.h +++ b/ReactCommon/fabric/components/text/paragraph/ParagraphComponentDescriptor.h @@ -52,8 +52,7 @@ class ParagraphComponentDescriptor final // `ParagraphShadowNode` uses this to cache the results of text rendering // measurements. - paragraphShadowNode->setMeasureCache( - measureCache_ ? measureCache_.get() : nullptr); + paragraphShadowNode->setMeasureCache(measureCache_.get()); paragraphShadowNode->dirtyLayout();