small fixes

This commit is contained in:
kremsy
2014-02-01 20:25:20 +01:00
committed by Steffen Schröder
parent 6a1a014696
commit 5ae3e43097
3 changed files with 8 additions and 4 deletions

View File

@ -135,10 +135,13 @@ class Server implements CallbackListener {
* @param bool $teamMode
*/
public function setTeamMode($teamMode = true) {
$oldStatus = $this->teamMode;
$this->teamMode = $teamMode;
// Trigger callback
$this->maniaControl->callbackManager->triggerCallback(self::CB_TEAM_STATUS_CHANGED, array(self::CB_TEAM_STATUS_CHANGED, $teamMode));
if ($oldStatus != $this->teamMode) {
$this->maniaControl->callbackManager->triggerCallback(self::CB_TEAM_STATUS_CHANGED, array(self::CB_TEAM_STATUS_CHANGED, $teamMode));
}
}
/**