Problem with vector and camera follow

Hello people , I’ m new hero and I would like to ask you for help if someone can help me . Im still watching tutorials and learning but I’ve got problem that im trying to fix since 2 days Im sure its something simple but I rly dont know where is the problem. So the problem is im creating 3d game and im at the moment that camera must follow the target , but after I click KeyCode.A the camera inverts and record the opposite side of the target. While im walking with KeyCode.D there is no problem but after I click A it just inverts. You can write me here but I will be more thankful if you write me at email - bogdanddimitrov@gmail.com . If someone can help please do it, i wish u a wonderful and sunny day!

In order for someone to help, I think you will need to post the relevant code. Please remember to use code tags when you do.