Skip to content

Commit 07754bd

Browse files
committed
Merge branch '2.2' of github.com:Codeception/Codeception into 2.2
2 parents 86a0acc + 60841ae commit 07754bd

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

src/Codeception/Lib/Connector/Guzzle.php

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,13 +79,18 @@ public function deleteHeader($name)
7979
unset($this->requestOptions['headers'][$name]);
8080
}
8181

82-
public function setAuth($username, $password)
82+
/**
83+
* @param string $username
84+
* @param string $password
85+
* @param string $type Default: 'basic'
86+
*/
87+
public function setAuth($username, $password, $type = 'basic')
8388
{
8489
if (!$username) {
8590
unset($this->requestOptions['auth']);
8691
return;
8792
}
88-
$this->requestOptions['auth'] = [$username, $password];
93+
$this->requestOptions['auth'] = [$username, $password, $type];
8994
}
9095

9196
/**

0 commit comments

Comments
 (0)