Beat mix project - struggle with toggle drum function

Hi everyone,

I’m starting with the beat mix project.
I am struggling with the toggle drum function which seem to work when I log the results but do not pass the test.
Below is my code:

// Drum Arrays

let kicks =[false, false, false, false,false, false, false, false,false, false, false, false,false, false, false, false];

let snares =[false, false, false, false,false, false, false, false,false, false, false, false,false, false, false, false];

let hiHats =[false, false, false, false,false, false, false, false,false, false, false, false,false, false, false, false];

let rideCymbals =[false, false, false, false,false, false, false, false,false, false, false, false,false, false, false, false];

// check validity of array name

function isArrayValid(drumArray)

{

    if (drumArray === kicks ||drumArray === snares ||drumArray === hiHats ||drumArray === rideCymbals)

    {return true} else {return false}

}

// change value of the drum array

function toggleDrum (drumArray, index) 

{

    if (isArrayValid(drumArray) && index>=0) 

    {

        drumArray[index] = !drumArray[index]

    }

}

Thanks a lot for your help!