From a69bb65d5b8181ef0b8333feeabf78bb51ee9b70 Mon Sep 17 00:00:00 2001 From: Vojtech Novak Date: Wed, 29 Jan 2025 23:58:04 +0100 Subject: [PATCH] refactor: use positive condition in RNCSafeAreaViewShadowNode.cpp (#580) * refactor: use positive condition * chore: run ci on changes to common --- .github/workflows/ios.yml | 1 + .../components/safeareacontext/RNCSafeAreaViewShadowNode.cpp | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/ios.yml b/.github/workflows/ios.yml index b02f354..ec2cf95 100644 --- a/.github/workflows/ios.yml +++ b/.github/workflows/ios.yml @@ -13,6 +13,7 @@ on: paths: - '.github/workflows/ios.yml' - 'ios/**' + - 'common/**' - 'example/ios/**' jobs: ios-build: diff --git a/common/cpp/react/renderer/components/safeareacontext/RNCSafeAreaViewShadowNode.cpp b/common/cpp/react/renderer/components/safeareacontext/RNCSafeAreaViewShadowNode.cpp index 0fe05e5..f66eab4 100644 --- a/common/cpp/react/renderer/components/safeareacontext/RNCSafeAreaViewShadowNode.cpp +++ b/common/cpp/react/renderer/components/safeareacontext/RNCSafeAreaViewShadowNode.cpp @@ -16,10 +16,10 @@ inline Style::Length valueFromEdges( Style::Length edge, Style::Length axis, Style::Length defaultValue) { - if (!edge.isUndefined()) { + if (edge.isDefined()) { return edge; } - if (!axis.isUndefined()) { + if (axis.isDefined()) { return axis; } return defaultValue;