Skip to content

Commit

Permalink
#8 AbstractClientObjectHandler fixation is wrong.
Browse files Browse the repository at this point in the history
  • Loading branch information
kilica committed Aug 16, 2012
1 parent 8dc545a commit 3464426
Showing 1 changed file with 41 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,14 @@ protected function _deleteImages(/*** XoopsSimpleObject ***/ $obj)
*/
protected function _isActivityClient(/*** mixed[] ***/ $conf)
{
return $conf[$this->_mClientConfig['activity']]==1 ? true : false;
$key ='activity';
if(! isset($this->_mClientConfig[$key])){
return false;
}
if(! isset($conf[$this->_mClientConfig[$key]])){
return false;
}
return $conf[$this->_mClientConfig[$key]]==1 ? true : false;
}

/**
Expand All @@ -357,7 +364,14 @@ protected function _isActivityClient(/*** mixed[] ***/ $conf)
*/
protected function _isTagClient(/*** mixed[] ***/ $conf)
{
return isset($conf[$this->_mClientConfig['tag']]) ? true : false;
$key ='tag';
if(! isset($this->_mClientConfig[$key])){
return false;
}
if(! isset($conf[$this->_mClientConfig[$key]])){
return false;
}
return $conf[$this->_mClientConfig[$key]] ? true : false;
}

/**
Expand All @@ -369,7 +383,14 @@ protected function _isTagClient(/*** mixed[] ***/ $conf)
*/
protected function _isWorkflowClient(/*** mixed[] ***/ $conf)
{
return isset($conf[$this->_mClientConfig['workflow']]) ? true : false;
$key ='workflow';
if(! isset($this->_mClientConfig[$key])){
return false;
}
if(! isset($conf[$this->_mClientConfig[$key]])){
return false;
}
return $conf[$this->_mClientConfig[$key]] ? true : false;
}

/**
Expand All @@ -381,7 +402,14 @@ protected function _isWorkflowClient(/*** mixed[] ***/ $conf)
*/
protected function _isImageClient(/*** mixed[] ***/ $conf)
{
return isset($conf[$this->_mClientConfig['image']]) ? true : false;
$key ='image';
if(! isset($this->_mClientConfig[$key])){
return false;
}
if(! isset($conf[$this->_mClientConfig[$key]])){
return false;
}
return $conf[$this->_mClientConfig[$key]] ? true : false;
}

/**
Expand All @@ -393,8 +421,15 @@ protected function _isImageClient(/*** mixed[] ***/ $conf)
*/
protected function _isMapClient(/*** mixed[] ***/ $conf)
{
return isset($conf[$this->_mClientConfig['map']]) ? true : false;
}
$key ='map';
if(! isset($this->_mClientConfig[$key])){
return false;
}
if(! isset($conf[$this->_mClientConfig[$key]])){
return false;
}
return $conf[$this->_mClientConfig[$key]]==1 ? true : false;
}

/**
* get client field name
Expand Down

0 comments on commit 3464426

Please sign in to comment.