Skip to content

Correct typing in phpdocs and fix getCustomDetails() #194

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 21, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions src/MessageBird/Objects/Contact.php
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ class Contact extends Base
/**
* Custom fields of the contact.
*
* @var array
* @var stdClass
*/
protected $customDetails = [];
/**
Expand All @@ -88,7 +88,7 @@ class Contact extends Base
/**
* The date and time of the updated of the contact in RFC3339 format (Y-m-d\TH:i:sP)
*
* @var string
* @var string|null
*/
protected $updatedDatetime;

Expand Down Expand Up @@ -122,7 +122,7 @@ public function getUpdatedDatetime(): ?string
return $this->updatedDatetime;
}

public function getCustomDetails(): array
public function getCustomDetails(): stdClass
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixes #199

{
return $this->customDetails;
}
Expand Down
2 changes: 1 addition & 1 deletion src/MessageBird/Objects/Conversation/Contact.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ class Contact extends Base
/**
* The MSISDN/phone number of this contact.
*
* @var string
* @var int|null
*/
public $msisdn;

Expand Down
2 changes: 1 addition & 1 deletion src/MessageBird/Objects/Conversation/Conversation.php
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ class Conversation extends Base
/**
* The URL of this conversation object.
*
* @var string
* @var string|null
*/
public $href;

Expand Down
4 changes: 2 additions & 2 deletions src/MessageBird/Objects/Conversation/Message.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ class Message extends Base implements JsonSerializable
* outbound messages sent through the API or 'received' (mobile-originated)
* for inbound messages from the contact.
*
* @var string
* @var string|null
*/
public $direction;

Expand All @@ -59,7 +59,7 @@ class Message extends Base implements JsonSerializable

/**
* Type of this message's content. Possible values: "text", "image",
* "audio", "video", "file", "location".
* "audio", "video", "file", "location", "hsm", "interactive", "email".
*
* @var string
*/
Expand Down
3 changes: 1 addition & 2 deletions src/MessageBird/Objects/Conversation/MessageReference.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,7 @@ class MessageReference extends Base
public $totalCount;

/**
*
* @var string
* @var string|null
*/
public $lastMessageId;
}
2 changes: 1 addition & 1 deletion src/MessageBird/Objects/Conversation/Webhook.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class Webhook extends Base implements JsonSerializable
/**
* The URL of this webhook object.
*
* @var string
* @var string|null
*/
public $href;

Expand Down