mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2025-01-19 02:56:15 +00:00
Adding missing 'recursive' option to DigestAuthenticate object.
Used integer casting in _findUser() method for 'recursive' option.
This commit is contained in:
parent
664b0538b8
commit
79cab67be7
2 changed files with 3 additions and 2 deletions
|
@ -82,7 +82,7 @@ abstract class BaseAuthenticate {
|
|||
}
|
||||
$result = ClassRegistry::init($userModel)->find('first', array(
|
||||
'conditions' => $conditions,
|
||||
'recursive' => $this->settings['recursive']
|
||||
'recursive' => (int)$this->settings['recursive']
|
||||
));
|
||||
if (empty($result) || empty($result[$model])) {
|
||||
return false;
|
||||
|
|
|
@ -78,6 +78,7 @@ class DigestAuthenticate extends BaseAuthenticate {
|
|||
),
|
||||
'userModel' => 'User',
|
||||
'scope' => array(),
|
||||
'recursive' => 0,
|
||||
'realm' => '',
|
||||
'qop' => 'auth',
|
||||
'nonce' => '',
|
||||
|
@ -166,7 +167,7 @@ class DigestAuthenticate extends BaseAuthenticate {
|
|||
}
|
||||
$result = ClassRegistry::init($userModel)->find('first', array(
|
||||
'conditions' => $conditions,
|
||||
'recursive' => 0
|
||||
'recursive' => (int)$this->settings['recursive']
|
||||
));
|
||||
if (empty($result) || empty($result[$model])) {
|
||||
return false;
|
||||
|
|
Loading…
Add table
Reference in a new issue