Fixing getAccessInformation()
This commit is contained in:
parent
48a8c8b89a
commit
192fa20284
|
@ -77,19 +77,4 @@ class Build extends BuildBase
|
|||
{
|
||||
return ($this->getStatus() === self::STATUS_SUCCESS);
|
||||
}
|
||||
|
||||
public function getAccessInformation($key = null)
|
||||
{
|
||||
$data = unserialize($this->data['access_information']);
|
||||
|
||||
if (is_null($key)) {
|
||||
$rtn = $data;
|
||||
} else if (isset($data[$key])) {
|
||||
$rtn = $data[$key];
|
||||
} else {
|
||||
$rtn = null;
|
||||
}
|
||||
|
||||
return $rtn;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -43,4 +43,19 @@ class Project extends ProjectBase
|
|||
|
||||
return null;
|
||||
}
|
||||
|
||||
public function getAccessInformation($key = null)
|
||||
{
|
||||
$data = unserialize($this->data['access_information']);
|
||||
|
||||
if (is_null($key)) {
|
||||
$rtn = $data;
|
||||
} elseif (isset($data[$key])) {
|
||||
$rtn = $data[$key];
|
||||
} else {
|
||||
$rtn = null;
|
||||
}
|
||||
|
||||
return $rtn;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue