File tree 4 files changed +84
-77
lines changed
4 files changed +84
-77
lines changed Original file line number Diff line number Diff line change @@ -14,15 +14,14 @@ class Request
14
14
protected $ parameters ;
15
15
protected $ httpMethod ;
16
16
protected $ httpUrl ;
17
- protected $ json ;
18
17
public static $ version = '1.0 ' ;
19
18
20
19
/**
21
20
* Constructor
22
21
*
23
22
* @param string $httpMethod
24
23
* @param string $httpUrl
25
- * @param array|null $parameters
24
+ * @param ? array $parameters
26
25
*/
27
26
public function __construct (
28
27
string $ httpMethod ,
@@ -55,7 +54,7 @@ public static function fromConsumerAndToken(
55
54
string $ httpMethod ,
56
55
string $ httpUrl ,
57
56
array $ parameters = [],
58
- $ json = false ,
57
+ array $ options = [] ,
59
58
) {
60
59
$ defaults = [
61
60
'oauth_version ' => Request::$ version ,
@@ -69,7 +68,7 @@ public static function fromConsumerAndToken(
69
68
70
69
// The json payload is not included in the signature on json requests,
71
70
// therefore it shouldn't be included in the parameters array.
72
- if ($ json ) {
71
+ if ($ options [ ' jsonPayload ' ] ?? false ) {
73
72
$ parameters = $ defaults ;
74
73
} else {
75
74
$ parameters = array_merge ($ defaults , $ parameters );
You can’t perform that action at this time.
0 commit comments