This repository was archived by the owner on Mar 23, 2024. It is now read-only.
File tree 2 files changed +8
-5
lines changed
2 files changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -23,10 +23,10 @@ trait OAuth2CSRFTokenTrait{
23
23
/**
24
24
* @param string|null $state
25
25
*
26
- * @return \chillerlan\OAuth\Core\OAuth2Interface
26
+ * @return void
27
27
* @throws \chillerlan\OAuth\Core\ProviderException
28
28
*/
29
- protected function checkState (string $ state = null ):OAuth2Interface {
29
+ protected function checkState (string $ state = null ):void {
30
30
31
31
if (empty ($ state ) || !$ this ->storage ->hasCSRFState ($ this ->serviceName )){
32
32
throw new ProviderException ('invalid state for ' .$ this ->serviceName );
@@ -38,8 +38,6 @@ protected function checkState(string $state = null):OAuth2Interface{
38
38
throw new ProviderException ('invalid CSRF state: ' .$ this ->serviceName .' ' .$ state );
39
39
}
40
40
41
- /** @noinspection PhpIncompatibleReturnTypeInspection */
42
- return $ this ;
43
41
}
44
42
45
43
/**
Original file line number Diff line number Diff line change @@ -60,6 +60,11 @@ abstract class APITestAbstract extends TestCase{
60
60
*/
61
61
protected $ dotEnv ;
62
62
63
+ /**
64
+ * @var float
65
+ */
66
+ protected $ requestDelay = 0.25 ;
67
+
63
68
protected function setUp (){
64
69
ini_set ('date.timezone ' , 'Europe/Amsterdam ' );
65
70
@@ -80,7 +85,7 @@ protected function setUp(){
80
85
'ca_info ' => $ this ->CFG .'/cacert.pem ' ,
81
86
'userAgent ' => 'chillerlanPhpOAuth/3.0.0 +https://github.com/chillerlan/php-oauth ' ,
82
87
// testHTTPClient
83
- 'sleep ' => 0.25 ,
88
+ 'sleep ' => $ this -> requestDelay ,
84
89
// logger
85
90
'minLogLevel ' => 'debug ' ,
86
91
];
You can’t perform that action at this time.
0 commit comments