Number Guesser Code Challenge

My question has to do with the project extension in the Number guesser Challenge.
Here’s the link to my code:

I can’t seem to get the alert (); within the compareGuesses function, functional.

This was the instruction;
Add functionality to check whether the user guess is between 0 and 9 and alert() the user that their number is out of range.

Please can anyone help tell what I’m doing wrong?

Well, for starters:

const compareGuesses = (humanGuess, computerGuess, targetGuess) => {
const humanDifference = getAbsoluteDistance (humanGuess, targetGuess);
const computerDifference = getAbsoluteDistance (computerGuess, targetGuess);

  return humanDifference <= computerDifference; //nothing after this line is reachable (it will never be executed)
   if (humanGuess > 0 && humanGuess < 9) {
    return updateScore ();
  } else {
     alert ('Number out of range');

Don’t forget what return does. It hands a value and control flow back to the caller.