Chore Door Step 61

I have some confusion in this section, Originally playDoor function was declared as below.

const playDoor =()=>{
  //decreases the numClosedDoors
  //checks winner by checking the numClosedDoors === 0
  if(numClosedDoors === 0){
     }else if(isBot(door)){
  //therefore its gameOver()

But at Step 61, the function needs an argument, which I get confused,How even is posible that the parameterless function get argumet without ant error, I would appreciate If anyone can explain to me,Thanks