How do I change this code so that i can press on the joystick more than once to shoot?

I get this error when i try to shoot using my joyatick:
ArgumentException: Index out of bounds.
UnityEngine.Input.GetTouch (System.Int32 index) <0x37332080 + 0x00092> in <6312b0c4d8544c04bf65f0a668bfa3ee>:0
ShootingPrefab.Update () (at Assets/C# code/ShootingPrefab.cs:25)

This is my code:
if (Input.touchCount > 0) {
Touch t = Input.GetTouch(1);
if (t.position.x > Screen.width / 2 && shootCooldown < 0)
{

            Shoot();
            

        }
    }

void Update()
{

    if (shootCooldown > 0)
    {
        shootCooldown -= Time.deltaTime;
    }
   
    if (Input.touchCount > 0) {
        Touch t = Input.GetTouch(1);
        if (t.position.x > Screen.width / 2 && shootCooldown < 0)
        {

            Shoot();
            

        }
    }