diff options
author | Mario <mario@mariovavti.com> | 2024-02-07 15:37:20 +0000 |
---|---|---|
committer | Mario <mario@mariovavti.com> | 2024-02-07 15:37:20 +0000 |
commit | 5f2e80849753928ee30e8420750b6218c64b4e25 (patch) | |
tree | cc3fdd173d7e9c4bc9bb85a4d93ccbd27fef3408 /Zotlabs/Lib/DReport.php | |
parent | 209651705db81d43a3a0546866467e0bf26fd7b9 (diff) | |
download | volse-hubzilla-5f2e80849753928ee30e8420750b6218c64b4e25.tar.gz volse-hubzilla-5f2e80849753928ee30e8420750b6218c64b4e25.tar.bz2 volse-hubzilla-5f2e80849753928ee30e8420750b6218c64b4e25.zip |
add uuid to dreport for internal use and and fix issues with conversation fetches
Diffstat (limited to 'Zotlabs/Lib/DReport.php')
-rw-r--r-- | Zotlabs/Lib/DReport.php | 52 |
1 files changed, 28 insertions, 24 deletions
diff --git a/Zotlabs/Lib/DReport.php b/Zotlabs/Lib/DReport.php index f4f098d19..71e39a9d7 100644 --- a/Zotlabs/Lib/DReport.php +++ b/Zotlabs/Lib/DReport.php @@ -8,22 +8,24 @@ class DReport { private $recipient; private $name; private $message_id; + private $message_uuid; private $status; private $date; - function __construct($location,$sender,$recipient,$message_id,$status = 'deliver') { - $this->location = $location; - $this->sender = $sender; - $this->recipient = $recipient; - $this->name = EMPTY_STR; - $this->message_id = $message_id; - $this->status = $status; - $this->date = datetime_convert(); + function __construct($location, $sender, $recipient, $message_id, $message_uuid = '', $status = 'deliver') { + $this->location = $location; + $this->sender = $sender; + $this->recipient = $recipient; + $this->name = EMPTY_STR; + $this->message_id = $message_id; + $this->message_uuid = $message_uuid; + $this->status = $status; + $this->date = datetime_convert(); } function update($status) { - $this->status = $status; - $this->date = datetime_convert(); + $this->status = $status; + $this->date = datetime_convert(); } function set_name($name) { @@ -36,24 +38,26 @@ class DReport { function set($arr) { - $this->location = $arr['location']; - $this->sender = $arr['sender']; - $this->recipient = $arr['recipient']; - $this->name = $arr['name']; - $this->message_id = $arr['message_id']; - $this->status = $arr['status']; - $this->date = $arr['date']; + $this->location = $arr['location']; + $this->sender = $arr['sender']; + $this->recipient = $arr['recipient']; + $this->name = $arr['name']; + $this->message_id = $arr['message_id']; + $this->message_uuid = $arr['message_uuid'] ?? ''; + $this->status = $arr['status']; + $this->date = $arr['date']; } function get() { return array( - 'location' => $this->location, - 'sender' => $this->sender, - 'recipient' => $this->recipient, - 'name' => $this->name, - 'message_id' => $this->message_id, - 'status' => $this->status, - 'date' => $this->date + 'location' => $this->location, + 'sender' => $this->sender, + 'recipient' => $this->recipient, + 'name' => $this->name, + 'message_id' => $this->message_id, + 'message_uuid' => $this->message_uuid, + 'status' => $this->status, + 'date' => $this->date ); } |