How to stop autojumping while holding space?

The code:

using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class Controller : MonoBehaviour
{
public GameObject cam;

Quaternion StartingRotation;

bool isGround;

public float Ver, Hor, Jump, RotVer, RotHor;

public float Speed = 10, JumpSpeed = 200, senssensitivity = 5;

//Jumping only on ground
void OnCollisionStay(Collision other)
{
    if (other.gameObject.tag == "Ground")
    {
        isGround = true;
    }
}

void OnCollisionExit(Collision other)
{
    if (other.gameObject.tag == "Ground")
    {
        isGround = false;
    }
}

void Start()
{
    StartingRotation = transform.rotation;
}

//Camera Rotating, Player movement
void Update()
{
    RotHor += Input.GetAxis("Mouse X") * senssensitivity;
    RotVer += Input.GetAxis("Mouse Y") * senssensitivity;

    RotVer = Mathf.Clamp(RotVer, -60, 60);

    Quaternion RotY = Quaternion.AngleAxis(RotHor, Vector3.up);
    Quaternion RotX = Quaternion.AngleAxis(-RotVer, Vector3.right);

    cam.transform.rotation = StartingRotation * transform.rotation * RotX;
    transform.rotation = StartingRotation * RotY;

    if (isGround)
    {
        Ver = Input.GetAxis("Vertical") * Time.deltaTime * Speed;
        Hor = Input.GetAxis("Horizontal") * Time.deltaTime * Speed;
        Jump = Input.GetAxis("Jump") * Time.deltaTime * JumpSpeed;
        GetComponent<Rigidbody>().AddForce(transform.up * Jump, ForceMode.Impulse);
    }
    transform.Translate(new Vector3(Hor, 0, Ver));
}

}

add a new variable bool justJumped = false.
When you jump set that to true.
then in line 49 change to something like this:

Jump = Input.GetAxis("Jump") * Time.deltaTime * JumpSpeed;
if(Jump > 0 && justJumped ) // this should be the case when Space is pressed (Jump > 0)
	Jump = 0f; // unset the input as space has not been released
else if(Jump == 0 && justJumped) // should be the case when Space is not pressed.
	justJumped = false; //space has been released