Can someone help me with a socket rotation snap issue?

Hi All,

I’m working on a project where you can grab actors and snap them on actors with the same socket names.
When it overlaps it finds the nearest socket, and when you release the actor it snaps in place. But… its not working when the actor is rotated.

Any help is appreciated!

Best regards,