Join curves issue

I am trying to join curves of two surfaces to create a closed loop, I have used this method in the past and it worked well. For some reason it does not work this time. Trying to understand why.

Attached grasshopper script

water_drop_pattern.gh (13 KB)

Trying to create this closed loop wall.

Join curves joins curves that have endpoints touching. Your curves aren’t touching.

Some options. Surface or line.

I understand my mistake now, I needed to flatten the curve

I understand my mistake now, I needed to flatten the curve on the join curve command