Problem with a single touch and swiping at the same time

Hello. Im quite new to Unity and Im currently working on my first game. In my game, player can rotate the camera by swiping left or right across the screen.
Code:

public class CameraRotator : MonoBehaviour //Script attached to the main camera
{
    private Vector3 firstpoint; 
    private Vector3 secondpoint;
    private float xAngle = 0.0f; 
    private float xAngTemp = 0.0f;
    private void Start()
    {
        xAngle = 0.0f;
        transform.rotation = Quaternion.Euler(0, xAngle, 0.0f);
    }
    private void Update()
    {
        if (Input.touchCount > 0)
        {
            if (Input.GetTouch(0).phase == TouchPhase.Began)
            {
                firstpoint = Input.GetTouch(0).position;
                xAngTemp = xAngle;
            }

            if (Input.GetTouch(0).phase == TouchPhase.Moved)
            {
                secondpoint = Input.GetTouch(0).position;
                xAngle = xAngTemp + (secondpoint.x - firstpoint.x) * 180.0f / Screen.width;
                transform.rotation = Quaternion.Euler(0, xAngle, 0.0f);
            }
        }
    }
}

But also, I want the player to be able to place an object with a simple single tap on the screen. Here is the basic code:

private void Update() 
{
        if (Input.touchCount > 0 && Input.GetTouch(0).phase == TouchPhase.Began)
        {
            //Code of placing object
	    }
}

With a normal single tap on the screen, everything works correctly (the object is placed and the camera does not rotate). But the problem is that the object is also placed once at the beginning when the camera is rotated (by moving my finger across the screen, left or right).

How can I make it so that the object is not placed when the camera is rotated. And so that the object is placed only with a single tap?

I know that the simplest solution would be to add a button to place the object. But I want to know if it’s possible to do it without the button.

Thanks in advance!

Dunno if this is what you’re looking for but this thread might help
https://forum.unity.com/threads/simple-swipe-and-tap-mobile-input.376160/