### Godot version

4.0.2

### System information

Windows 10 x64

### Issue description

![image](https://user-images.githubusercontent.com/2223172/231459722-294d88f9-dae3-4a3f-8e7f-e5340ca0dd25.png)
Both paths point to the same node, but the second one appears as if the node wasn't found. I assume this is because the NodePaths in array don't have the scene's node as "parent", so the path can't be resolved properly.

### Steps to reproduce

1.
```GDScript
@export var np1: NodePath
@export var np2: Array[NodePath]
```
2. Assign the same node
3. Compare the results

### Minimal reproduction project

N/A
node->_acquire_unique_name_in_owner();
					}
				}
			}
			
			if (p_edit_state == GEN_EDIT_STATE_MAIN) {
				_sanitize_node_pinned_properties(node);
			} else {
				node->remove_meta("_edit_pinned_properties_");
			}
		}
		if (missing_node) {
			missing_node->set_recording_properties(false);
		}
		ret_nodes[i] = node;
		if (node && gen_node_path_cache && ret_nodes[0]) {
			NodePath n2 = ret_nodes[0]->get_path_to(node);
			node_path_cache[n2] = i;
		}
	}
	for (const DeferredNodePathProperties &dnp : deferred_node_paths) {
		
		Node *other = dnp.base->get_node_or_null(dnp.path);
		const String string_property = dnp.property;
		if (string_property.contains("/indices/")) {
			
			const String base_property = string_property.get_slice("/", 0);
			const int index = string_property.get_slice("/", 2).to_int();
			Array array = dnp.base->get(base_property);
			if (array.size() >= index) {