Increase value slider by button ui

I guys I have a problem: I want that when I click a UI button, my slider increase value but don’t work….why (I attach script)? In the same slider, I have another script that decrease slider on time (attach to the slider and this works). Do you think the two scripts conflict? Thank a lot.

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

public class increaseslider : MonoBehaviour
{

    public Slider healthbar;
  
    public GameObject button;


    public void OnClick()
    {
        healthbar.value += 20;
        Destroy(button);
    }

    }

SECOND SCRIPT(SLIDER)

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
using UnityEngine.SceneManagement;

public class stamina : MonoBehaviour
{
    public Slider slider;
    public float time = 3000f;
    public AudioSource scream;

    void Start()
    {
        slider.maxValue = 3000f;
        slider.minValue = 0f;
    }


    void Update()
    {
        time -= Time.deltaTime;
        slider.value = time;

        if (slider.value <= 0)
        {
            scream.Play();
            StartCoroutine(LateCall());
        }

        IEnumerator LateCall()
        {

            yield return new WaitForSeconds(2);
            SceneManager.LoadScene("menu");
        }
           


    }
}

You are correct : the two script conflicts.
Your second script set the value of the slider every frame. So whatever value your are giving to it with other script, it won’t matter: you will always override it with your time value.

One easy solution : instead of

time -= Time.deltaTime;
        slider.value = time;

just do :

        slider.value -= Time.deltaTime;