From fbd92c2c4248d026397613e7b0197a10a20bafe8 Mon Sep 17 00:00:00 2001 From: Michal Voscek Date: Mon, 16 Apr 2018 19:20:49 +0200 Subject: [PATCH] Add has account to API --- src/Twisto/Invoice.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/Twisto/Invoice.php b/src/Twisto/Invoice.php index c8e17f9..17e7f29 100644 --- a/src/Twisto/Invoice.php +++ b/src/Twisto/Invoice.php @@ -46,6 +46,9 @@ class Invoice /** @var Item[] */ public $items; + /** @var bool */ + public $has_account; + /** * @param Twisto $twisto * @param string $invoice_id @@ -188,6 +191,8 @@ private function deserialize($data) $this->items = array_map(function($item) { return Item::deserialize($item); }, $data['items']); + + $this->has_account = (bool)$data['has_account']; } private function serialize() @@ -205,4 +210,4 @@ private function serialize() return $data; } -} \ No newline at end of file +}