Assigning undefined to a singular linked field should not assign null
Summary:
* `data.singular_linked_field = undefined` was being translated to `setValue(null, ...)` when in fact, it should be `setValue(undefined, ...)`
* Fix that
@@ -214,7 +214,7 @@ function createSetterForSingularLinkedField<TQuery: OperationType>(
const variables = getArgumentValues(selection.args ?? [], queryVariables);
if (newValue == null) {
// $FlowFixMe[unclear-type] No good way to type these variables
- recordProxy.setValue(null, selection.name, (variables: any));
+ recordProxy.setValue(newValue, selection.name, (variables: any));
} else {
const {__id} = newValue;
if (__id == null) {
