public function __construct() { parent::__construct(); $this->_validateUser(); if (Dura_Class_RoomSession::isCreated()) { $this->id = Dura_Class_RoomSession::get('id'); } else { $this->id = Dura::post('id'); } if (!$this->id) { Dura::redirect('lounge'); } $this->roomHandler = new Dura_Model_RoomHandler(); $this->roomModel = $this->roomHandler->load($this->id); if (!$this->roomModel) { Dura_Class_RoomSession::delete(); Dura::trans(t("Room not found.", 'lounge')); } }
protected function _redirectToRoom() { if (Dura_Class_RoomSession::isCreated()) { Dura::redirect('room'); } }