What does console.log mean in a js if conditional statement?

recently I saw a piece of js code in the source code of WeChat Mini Programs, but I couldn"t figure out what it meant. The code is as follows:

if (console.log(a), void 0 !== a.bet) 
    return wx.showToast({
            title: "title",
            icon: "none"
        });

the two parameters separated by commas in if () parentheses, console.log (a) and void 0! = = a.bet, understand that if you put them together, you don"t know why you write this and what it means. Please give me an answer, thank you very much!

Mar.18,2021

this is the comma expression . The comma expression is executed from left to right and returns the value of the last expression

.
  Link description  

Menu