description = $hardwareProfile->getDescription(); $this->comments = $hardwareProfile->getComments(); if($hardwareProfile->getClient()) { $this->client = new ClientOutput($hardwareProfile->getClient()); } $this->hardwareCollection = $hardwareProfile->getHardwareCollection()->map( fn(Hardware $hardware) => new HardwareOutput($hardware) )->toArray(); $this->createdAt = $hardwareProfile->getCreatedAt(); $this->createdBy = $hardwareProfile->getCreatedBy(); } }