Skip to content

Commit 4d731c2

Browse files
authored
Merge pull request #203 from hanazarraa/nullable_params_complete
2 parents 8a68b2e + c80d1d6 commit 4d731c2

25 files changed

+243
-205
lines changed

src/Parameters/CreateMeetingParameters.php

Lines changed: 87 additions & 87 deletions
Large diffs are not rendered by default.

src/Parameters/DeleteRecordingsParameters.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,14 +28,14 @@ class DeleteRecordingsParameters extends BaseParameters
2828
/**
2929
* @var string
3030
*/
31-
private $recordingId;
31+
private ?string $recordingId = null;
3232

3333
/**
3434
* DeleteRecordingsParameters constructor.
3535
*
3636
* @param mixed $recordingId
3737
*/
38-
public function __construct($recordingId)
38+
public function __construct($recordingId = null)
3939
{
4040
$this->recordingId = $recordingId;
4141
}

src/Parameters/EndMeetingParameters.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,22 +28,22 @@ class EndMeetingParameters extends BaseParameters
2828
/**
2929
* @var string
3030
*/
31-
private $meetingId;
31+
private ?string $meetingId = null;
3232

3333
/**
3434
* @deprecated
3535
*
3636
* @var string
3737
*/
38-
private $password;
38+
private ?string $password = null;
3939

4040
/**
4141
* EndMeetingParameters constructor.
4242
*
4343
* @param string $meetingId
4444
* @param string $password
4545
*/
46-
public function __construct($meetingId, $password = '')
46+
public function __construct($meetingId = null, $password = null)
4747
{
4848
$this->password = $password;
4949
$this->meetingId = $meetingId;

src/Parameters/GetMeetingInfoParameters.php

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -28,24 +28,24 @@ class GetMeetingInfoParameters extends BaseParameters
2828
/**
2929
* @var string
3030
*/
31-
private $meetingId;
31+
private ?string $meetingId = null;
3232

3333
/**
3434
* @var int
3535
*/
36-
private $offset;
36+
private ?int $offset = null;
3737

3838
/**
3939
* @var int
4040
*/
41-
private $limit;
41+
private ?int $limit = null;
4242

4343
/**
4444
* GetMeetingInfoParameters constructor.
4545
*
4646
* @param mixed $meetingId
4747
*/
48-
public function __construct($meetingId)
48+
public function __construct($meetingId = null)
4949
{
5050
$this->meetingId = $meetingId;
5151
}
@@ -70,7 +70,7 @@ public function setMeetingId($meetingId)
7070
return $this;
7171
}
7272

73-
public function getOffset(): int
73+
public function getOffset()
7474
{
7575
return $this->offset;
7676
}
@@ -82,7 +82,7 @@ public function setOffset(int $offset): GetMeetingInfoParameters
8282
return $this;
8383
}
8484

85-
public function getLimit(): int
85+
public function getLimit()
8686
{
8787
return $this->limit;
8888
}

src/Parameters/GetRecordingTextTracksParameters.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,14 +28,14 @@ class GetRecordingTextTracksParameters extends MetaParameters
2828
/**
2929
* @var string
3030
*/
31-
private $recordId;
31+
private ?string $recordId = null;
3232

3333
/**
3434
* GetRecordingTextTracksParameters constructor.
3535
*
3636
* @param mixed $recordId
3737
*/
38-
public function __construct($recordId)
38+
public function __construct($recordId = null)
3939
{
4040
$this->recordId = $recordId;
4141
}

src/Parameters/GetRecordingsParameters.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,17 +28,17 @@ class GetRecordingsParameters extends MetaParameters
2828
/**
2929
* @var string
3030
*/
31-
private $meetingId;
31+
private ?string $meetingId = null;
3232

3333
/**
3434
* @var string
3535
*/
36-
private $recordId;
36+
private ?string $recordId = null;
3737

3838
/**
3939
* @var string
4040
*/
41-
private $state;
41+
private ?string $state = null;
4242

4343
/**
4444
* @return string

src/Parameters/HooksCreateParameters.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,17 +25,17 @@ class HooksCreateParameters extends BaseParameters
2525
/**
2626
* @var string
2727
*/
28-
private $callbackUrl;
28+
private ?string $callbackUrl = null;
2929

3030
/**
3131
* @var string
3232
*/
33-
private $meetingId;
33+
private ?string $meetingId = null;
3434

3535
/**
3636
* @var bool
3737
*/
38-
private $getRaw;
38+
private ?bool $getRaw = null;
3939

4040
/**
4141
* HooksCreateParameters constructor.
@@ -115,7 +115,7 @@ public function getHTTPQuery()
115115
$queries = [
116116
'callbackURL' => $this->callbackUrl,
117117
'meetingID' => $this->meetingId,
118-
'getRaw' => $this->getRaw ? 'true' : 'false',
118+
'getRaw' => !is_null($this->getRaw) ? ($this->getRaw ? 'true' : 'false') : $this->getRaw,
119119
];
120120

121121
return $this->buildHTTPQuery($queries);

src/Parameters/HooksDestroyParameters.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,14 +25,14 @@ class HooksDestroyParameters extends BaseParameters
2525
/**
2626
* @var string
2727
*/
28-
private $hookId;
28+
private ?string $hookId = null;
2929

3030
/**
3131
* HooksDestroyParameters constructor.
3232
*
3333
* @param mixed $hookId
3434
*/
35-
public function __construct($hookId)
35+
public function __construct($hookId = null)
3636
{
3737
$this->hookId = $hookId;
3838
}

src/Parameters/InsertDocumentParameters.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,14 +30,14 @@ class InsertDocumentParameters extends BaseParameters
3030
/**
3131
* @var string
3232
*/
33-
private $meetingId;
33+
private ?string $meetingId = null;
3434

3535
/**
3636
* EndMeetingParameters constructor.
3737
*
3838
* @param string $meetingId
3939
*/
40-
public function __construct($meetingId)
40+
public function __construct($meetingId = null)
4141
{
4242
$this->meetingId = $meetingId;
4343
}

src/Parameters/IsMeetingRunningParameters.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,14 +28,14 @@ class IsMeetingRunningParameters extends BaseParameters
2828
/**
2929
* @var string
3030
*/
31-
private $meetingId;
31+
private ?string $meetingId = null;
3232

3333
/**
3434
* IsMeetingRunningParameters constructor.
3535
*
3636
* @param mixed $meetingId
3737
*/
38-
public function __construct($meetingId)
38+
public function __construct($meetingId = null)
3939
{
4040
$this->meetingId = $meetingId;
4141
}

0 commit comments

Comments
 (0)