public function toArray()
{
$result = ['title' => $this->title, 'price' => $this->price];
if (!is_null($this->subtitle)) {
$result['subtitle'] = $this->subtitle;
}
if (!is_null($this->quantity)) {
$result['quantity'] = $this->quantity;
}
if (!is_null($this->currency)) {
$result['currency'] = $this->currency;
}
if (!is_null($this->image_url)) {
$result['image_url'] = $this->image_url;
}
return $result;
}