Skip to content

Commit e507bbc

Browse files
Send null for a gradient color hint in View Props 2.0 payloads
1 parent 8073e98 commit e507bbc

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • packages/react-native/ReactCommon/react/renderer/graphics

‎packages/react-native/ReactCommon/react/renderer/graphics/ColorStop.cpp‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ namespace facebook::react {
1212
#ifdef RN_SERIALIZABLE_STATE
1313
folly::dynamic ColorStop::toDynamic() const {
1414
folly::dynamic result = folly::dynamic::object();
15-
result["color"] = *color;
15+
result["color"] = color ? folly::dynamic(*color) : folly::dynamic(nullptr);
1616
result["position"] = position.toDynamic();
1717
return result;
1818
}

0 commit comments

Comments
 (0)