public function allowBonus($game, $user)
    {
        if (! $game->getPlayBonus() || $game->getPlayBonus() == 'none') {
            return false;
        } elseif ($game->getPlayBonus() == 'one') {
            if ($this->getEntryMapper()->findOneBy(array(
                'game' => $game,
                'user' => $user,
                'bonus' => 1
            ))) {
                return false;
            } else {
                return true;
            }
        } elseif ($game->getPlayBonus() == 'per_entry') {
            return $this->getEntryMapper()->checkBonusEntry($game, $user);
        }

        return false;
    }
public function allowBonus($game, $user)
    {
        if (! $game->getPlayBonus() || $game->getPlayBonus() == 'none') {
            return false;
        } elseif ($game->getPlayBonus() == 'one') {
            if ($this->getEntryMapper()->findOneBy(array(
                'game' => $game,
                'user' => $user,
                'bonus' => 1
            ))) {
                return false;
            } else {
                return true;
            }
        } elseif ($game->getPlayBonus() == 'per_entry') {
            return $this->getEntryMapper()->checkBonusEntry($game, $user);
        }

        return false;
    }
public function allowBonus ( $ game , $ user ) { if ( ! $ game -> getPlayBonus ( ) || $ game -> getPlayBonus ( ) == 'none' ) { return false ; } elseif ( $ game -> getPlayBonus ( ) == 'one' ) { if ( $ this -> getEntryMapper ( ) -> findOneBy ( array ( 'game' => $ game , 'user' => $ user , 'bonus' => 1 ) ) ) { return false ; } else { return true ; } } elseif ( $ game -> getPlayBonus ( ) == 'per_entry' ) { return $ this -> getEntryMapper ( ) -> checkBonusEntry ( $ game , $ user ) ; } return false ; }
Is it possible to trigger a bonus entry ?

@param unknown_type $game
@param unknown_type $user
Is it possible to trigger a bonus entry ?