Fixed skeleton straightening

Skeleton straightening was causing issueas with multiple branch nodes