Update system after connection

Hello. I was wondering if there is an easy way to update a duct system or similar after using API to replace connections. I know I could move it 0.1 and back and it would update the connection but I was hoping there would be a method that wouldn’t require moving.

Below is the picture of before and after my script:

The graph replaces a family in a system and connects it directly to the closest duct in the system. But after removing the fittings, the ducts do not physically connect into the family.

Any help is appreciated.