Skip to content
This repository has been archived by the owner on Jan 29, 2020. It is now read-only.

Commit

Permalink
Merge branch 'master' of https://github.com/Yousha/zf2 into release
Browse files Browse the repository at this point in the history
  • Loading branch information
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 22 deletions.
10 changes: 4 additions & 6 deletions src/Adapter/DbTable.php
Original file line number Diff line number Diff line change
Expand Up @@ -295,14 +295,12 @@ public function getResultRowObject($returnColumns = null, $omitColumns = null)
}
return $returnObject;

} else {

foreach ($this->resultRow as $resultColumn => $resultValue) {
$returnObject->{$resultColumn} = $resultValue;
}
return $returnObject;
}

foreach ($this->resultRow as $resultColumn => $resultValue) {
$returnObject->{$resultColumn} = $resultValue;
}
return $returnObject;
}

/**
Expand Down
28 changes: 14 additions & 14 deletions src/Adapter/Http.php
Original file line number Diff line number Diff line change
Expand Up @@ -589,9 +589,9 @@ protected function _digestAuth($header)
if ($this->_secureStringCompare($digest, $data['response'])) {
$identity = array('username'=>$data['username'], 'realm'=>$data['realm']);
return new Authentication\Result(Authentication\Result::SUCCESS, $identity);
} else {
return $this->_challengeClient();
}

return $this->_challengeClient();
}

/**
Expand Down Expand Up @@ -682,9 +682,9 @@ protected function _parseDigestAuth($header)
}
if (!ctype_xdigit($temp[1])) {
return false;
} else {
$data['nonce'] = $temp[1];
}

$data['nonce'] = $temp[1];
$temp = null;

$ret = preg_match('/uri="([^"]+)"/', $header, $temp);
Expand Down Expand Up @@ -715,9 +715,9 @@ protected function _parseDigestAuth($header)
}
if (32 != strlen($temp[1]) || !ctype_xdigit($temp[1])) {
return false;
} else {
$data['response'] = $temp[1];
}

$data['response'] = $temp[1];
$temp = null;

// The spec says this should default to MD5 if omitted. OK, so how does
Expand All @@ -739,9 +739,9 @@ protected function _parseDigestAuth($header)
}
if (!ctype_print($temp[1])) {
return false;
} else {
$data['cnonce'] = $temp[1];
}

$data['cnonce'] = $temp[1];
$temp = null;

// If the server sent an opaque value, the client must send it back
Expand All @@ -767,9 +767,9 @@ protected function _parseDigestAuth($header)
if (!$this->ieNoOpaque &&
(32 != strlen($temp[1]) || !ctype_xdigit($temp[1]))) {
return false;
} else {
$data['opaque'] = $temp[1];
}

$data['opaque'] = $temp[1];
$temp = null;
}

Expand All @@ -781,9 +781,9 @@ protected function _parseDigestAuth($header)
}
if (!in_array($temp[1], $this->supportedQops)) {
return false;
} else {
$data['qop'] = $temp[1];
}

$data['qop'] = $temp[1];
$temp = null;

// Not optional in this implementation. The spec says this value
Expand All @@ -795,9 +795,9 @@ protected function _parseDigestAuth($header)
}
if (8 != strlen($temp[1]) || !ctype_xdigit($temp[1])) {
return false;
} else {
$data['nc'] = $temp[1];
}

$data['nc'] = $temp[1];
$temp = null;

return $data;
Expand Down
4 changes: 2 additions & 2 deletions src/Adapter/Ldap.php
Original file line number Diff line number Diff line change
Expand Up @@ -439,9 +439,9 @@ protected function checkGroupMembership(ZendLdap\Ldap $ldap, $canonicalName, $dn

if ($result === 1) {
return true;
} else {
return 'Failed to verify group membership with ' . $group->toString();
}

return 'Failed to verify group membership with ' . $group->toString();
}

/**
Expand Down

0 comments on commit c8941af

Please sign in to comment.