private function wasCorrectGoalsTip(\AppBundle\Entity\Game $g, $amountOfGoals) { if ($g->getOver() > $g->getUnder() && $amountOfGoals > $g->getGoals()) { //correct over tip return true; } if ($g->getUnder() > $g->getOver() && $amountOfGoals < $g->getGoals()) { return true; } return false; // incorrect }