C# Code error out of nowhere. Please help.,Error in C# Script : The modifier 'private' is not valid for this item

So, I was using this casual movement and ground check script, but it doesn’t work anymore. 30 minutes ago it worked, but now it SOMEHOW doesn’t. please help.
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class PlayerMovement : MonoBehaviour
{
public float speed;
private float Move;

public float jump;

public bool isJumping;

private Rigidbody2D rb;
// Start is called before the first frame update
void Start()
{
    rb = GetComponent<Rigidbody2D>();
}

// Update is called once per frame
void Update()
{
    Move = Input.GetAxis("Horizontal");

    rb.velocity = new Vector2(speed * Move, rb.velocity.y);

    if (Input.GetButtonDown("Jump") && isJumping == false)
    {
        rb.AddForce(new Vector2(rb.velocity.x, jump));
        Debug.Log("jump");
    }
}

private void OnCollisionEnter2D(Collision2D other)
{
    if (other.gameObject.CompareTag("Ground"))
    {
        isJumping = false;
    }

private void OnCollisionExit2D(Collision2D other)
    {
        if (other.gameObject.CompareTag("Ground"))
        {
            isJumping = true;
    }
 }

}
}
,So, Like 30 minutes ago this script was working but now somehow it doesn’t. This is the script :
using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class PlayerMovement : MonoBehaviour
{
public float speed;
private float Move;

public float jump;

public bool isJumping;

private Rigidbody2D rb;
// Start is called before the first frame update
void Start()
{
    rb = GetComponent<Rigidbody2D>();
}

// Update is called once per frame
void Update()
{
    Move = Input.GetAxis("Horizontal");

    rb.velocity = new Vector2(speed * Move, rb.velocity.y);

    if (Input.GetButtonDown("Jump") && isJumping == false)
    {
        rb.AddForce(new Vector2(rb.velocity.x, jump));
        Debug.Log("jump");
    }
}

private void OnCollisionEnter2D(Collision2D other)
{
    if (other.gameObject.CompareTag("Ground"))
    {
        isJumping = false;
    }

private void OnCollisionExit2D(Collision2D other)
    {
        if (other.gameObject.CompareTag("Ground"))
        {
            isJumping = true;
    }
 }

}
}

Error is in the 43rd line. The line is a normal groundcheck, I don’t know why it isn’t working.

You have the “OnCollisionExit2D” method inside the “OnCollisionEnter2D” method.

Before:

    private void OnCollisionEnter2D(Collision2D other)
    {
        if (other.gameObject.CompareTag("Ground"))
        {
            isJumping = false;
        }
        private void OnCollisionExit2D(Collision2D other)
        {
            if (other.gameObject.CompareTag("Ground"))
            {
                isJumping = true;
            }
        }
    }

After:

    private void OnCollisionEnter2D(Collision2D other)
    {
        if (other.gameObject.CompareTag("Ground"))
        {
            isJumping = false;
        }
    }
    private void OnCollisionExit2D(Collision2D other)
    {
        if (other.gameObject.CompareTag("Ground"))
        {
            isJumping = true;
        }
    }