* fix bug #976.
This commit is contained in:
@@ -198,7 +198,15 @@ class projectModel extends model
|
||||
if($projectID > 0) $this->session->set('project', (int)$projectID);
|
||||
if($projectID == 0 and $this->cookie->lastProject) $this->session->set('project', (int)$this->cookie->lastProject);
|
||||
if($projectID == 0 and $this->session->project == '') $this->session->set('project', key($projects));
|
||||
if(!isset($projects[$this->session->project])) $this->session->set('project', key($projects));
|
||||
if(!isset($projects[$this->session->project]))
|
||||
{
|
||||
$this->session->set('project', key($projects));
|
||||
if($projectID > 0)
|
||||
{
|
||||
echo(js::alert($this->lang->project->accessDenied));
|
||||
die(js::locate('back'));
|
||||
}
|
||||
}
|
||||
return $this->session->project;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user